1400
Is it possible to define my values for sorting
with AxG2antt1 do
begin
	(Columns.Add('C1') as EXG2ANTTLib.Column).SortType := EXG2ANTTLib.SortTypeEnum.SortUserDataString;
	Columns.Add('C2');
	with Items do
	begin
		h := AddItem('Cell 1');
		CellData[TObject(h),TObject(0)] := '3.your extra data';
		CellValue[TObject(h),TObject(1)] := 'SortValue=3';
		h := AddItem('Cell 1.1');
		CellData[TObject(h),TObject(0)] := '1.your extra data';
		CellValue[TObject(h),TObject(1)] := ' SortValue=1';
		h := AddItem('Cell 1.2');
		CellData[TObject(h),TObject(0)] := '5.your extra data';
		CellValue[TObject(h),TObject(1)] := ' SortValue=5';
		h := AddItem('Cell 1.3');
		CellData[TObject(h),TObject(0)] := '2.your extra data';
		CellValue[TObject(h),TObject(1)] := ' SortValue=2';
	end;
end
1399
I have multiple dropdown lists, that are depending on each other, that means that the values in dropdown list no. 2 is based on the users selection in dropdown list no 1. How can I do this
// EditOpen event - Occurs when the edit operation starts.
procedure TWinForm1.AxG2antt1_EditOpen(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		with Items do
		begin
			v := CellValue[TObject(FocusItem),TObject(0)];
			c := CellCaption[TObject(FocusItem),TObject(0)];
		end;
		with Columns.Item[TObject(1)].Editor do
		begin
			ClearItems();
			AddItem(v,c,Nil);
		end;
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	with (Columns.Add('DropDownList') as EXG2ANTTLib.Column) do
	begin
		with Editor do
		begin
			EditType := EXG2ANTTLib.EditTypeEnum.DropDownListType;
			AddItem(1,'First',Nil);
			AddItem(2,'Second',Nil);
			AddItem(3,'Third',Nil);
		end;
	end;
	DrawGridLines := EXG2ANTTLib.GridLinesEnum.exAllLines;
	(Columns.Add('DropDownList-Related') as EXG2ANTTLib.Column).Editor.EditType := EXG2ANTTLib.EditTypeEnum.DropDownListType;
	with Items do
	begin
		CellValue[TObject(AddItem(TObject(1))),TObject(1)] := TObject(-1);
		CellValue[TObject(AddItem(TObject(2))),TObject(1)] := TObject(-1);
		CellValue[TObject(AddItem(TObject(3))),TObject(1)] := TObject(-1);
		LockedItemCount[EXG2ANTTLib.VAlignmentEnum.exBottom] := 1;
		h := LockedItem[EXG2ANTTLib.VAlignmentEnum.exBottom,0];
		ItemDivider[h] := 0;
		ItemDividerLineAlignment[h] := EXG2ANTTLib.DividerAlignmentEnum.DividerTop;
		CellEditorVisible[TObject(h),TObject(0)] := EXG2ANTTLib.EditorVisibleEnum.exEditorHidden;
		CellSingleLine[TObject(h),TObject(0)] := EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap;
		CellValueFormat[TObject(h),TObject(0)] := EXG2ANTTLib.ValueFormatEnum.exHTML;
		CellValue[TObject(h),TObject(0)] := 'The drop down editor in the second column is filled during the <b>EditOpen event</b>, and the values are based on the selection ' + 
	'on the first column.';
	end;
	EndUpdate();
end
1398
Is it possible background color displayed when the mouse passes over an item
with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Def');
	HotBackColor := Color.FromArgb(0,0,128);
	HotForeColor := Color.FromArgb(255,255,255);
	with Items do
	begin
		AddItem('Item A');
		AddItem('Item B');
		AddItem('Item C');
	end;
	EndUpdate();
end
1397
Is it possible to magnify a specified date and apply a different background color

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Tasks');
	with Chart do
	begin
		DrawLevelSeparator := EXG2ANTTLib.LevelLineEnum.exLevelNoLine;
		PaneWidth[False] := 64;
		FirstVisibleDate := '11/23/2011';
		LevelCount := 3;
		FirstWeekDay := EXG2ANTTLib.WeekDayEnum.exMonday;
		AllowInsideZoom := True;
		InsideZooms.Add('11/29/2011').AllowCustomFormat := True;
		with InsideZooms.Item['11/29/2011'] do
		begin
			Width := 68;
			CustomFormat.BackColorChart := $e0e0e0;
		end;
	end;
	with Items do
	begin
		hA := AddItem('Task A');
		AddBar(hA,'Task','11/24/2011','11/26/2011','A',Nil);
		hB := AddItem('Task B');
		AddBar(hB,'Task','11/28/2011','12/1/2011','B',Nil);
		AddLink('LinkAB',hA,'A',hB,'B');
		Link['LinkAB',EXG2ANTTLib.LinkPropertyEnum.exLinkStyle] := TObject(2);
		Link['LinkAB',EXG2ANTTLib.LinkPropertyEnum.exLinkWidth] := TObject(2);
	end;
	EndUpdate();
end
1396
Could you please tell me how to add multiple bars to the one line

with AxG2antt1 do
begin
	BeginUpdate();
	Chart.FirstVisibleDate := '1/1/2002';
	Columns.Add('Task');
	with Items do
	begin
		h := AddItem('Task');
		AddBar(h,'Task','1/2/2002','1/4/2002','A',Nil);
		AddBar(h,'Task','1/6/2002','1/10/2002','B',Nil);
		ItemBar[h,'A',EXG2ANTTLib.ItemBarPropertyEnum.exBarColor] := TObject(255);
		AddLink('AB',h,'A',h,'B');
	end;
	EndUpdate();
end
1395
My development environment does not have any Object,GetOcx,DefaultDispatch,GetControlUnknown,nativeObject, ... property, is there any alternative I can pass the component to PrintExt so I can get printed
with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	Chart.FirstVisibleDate := '1/1/2001';
	with Items do
	begin
		h1 := AddItem('Task 1');
		AddBar(h1,'Task','1/2/2001','1/4/2001','K1',Nil);
		h2 := AddItem('Task 2');
		AddBar(h2,'Task','1/5/2001','1/7/2001','K2',Nil);
		AddLink('L1',h1,'K1',h2,'K2');
		Link['L1',EXG2ANTTLib.LinkPropertyEnum.exLinkStartPos] := TObject(0);
	end;
	EndUpdate();
	Template := 'Dim p;p = CreateObject(`Exontrol.Print`);p.PrintExt = Me;p.AutoRelease = False;p.Preview();';
end
1394
My development environment does not have any Object,GetOcx,DefaultDispatch,GetControlUnknown,nativeObject, ... property, is there any alternative I can pass the component to PrintExt so I can get printed
with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	Chart.FirstVisibleDate := '1/1/2001';
	with Items do
	begin
		h1 := AddItem('Task 1');
		AddBar(h1,'Task','1/2/2001','1/4/2001','K1',Nil);
		h2 := AddItem('Task 2');
		AddBar(h2,'Task','1/5/2001','1/7/2001','K2',Nil);
		AddLink('L1',h1,'K1',h2,'K2');
		Link['L1',EXG2ANTTLib.LinkPropertyEnum.exLinkStartPos] := TObject(0);
	end;
	EndUpdate();
	with (ComObj.CreateComObject(ComObj.ProgIDToClassID('Exontrol.Print')) as EXPRINTLib.Print) do
	begin
		PrintExt := (AxG2antt1.ExecuteTemplate('me') as EXG2ANTTLib.G2antt).DefaultDispatch;
		Preview();
	end;
end
1393
Is it possible to display the bar's captions or labels with a different font/size

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	DefaultItemHeight := 24;
	with Chart do
	begin
		PaneWidth[False] := 64;
		FirstVisibleDate := '1/1/2001';
		LevelCount := 2;
	end;
	with Items do
	begin
		h := AddItem('Default');
		AddBar(h,'Task','1/2/2001','1/6/2001','','This is a the control''s font');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		h := AddItem('Smaller');
		AddBar(h,'Task','1/2/2001','1/6/2001','','<font ;5>This is a the control''s font with a smaller size');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		h := AddItem('Larger');
		AddBar(h,'Task','1/2/2001','1/6/2001','','<font ;15>This is a the control''s font with a larger size');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		h := AddItem('Tahoma 1');
		AddBar(h,'Task','1/2/2001','1/6/2001','','<font Tahoma>This is using a Tahoma font');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		h := AddItem('Tahoma 2');
		AddBar(h,'Task','1/2/2001','1/6/2001','','<font Tahoma;14>This is using a <b>Tahoma</b> font with a different size');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
	end;
	EndUpdate();
end
1392
How can I apply the same ConditionalFormat on more than 1(one) column (multiple columns and not on item)
with AxG2antt1 do
begin
	BeginUpdate();
	with ConditionalFormats.Add('1','K1') do
	begin
		BackColor := $ff;
		ApplyTo := EXG2ANTTLib.FormatApplyToEnum($1);
	end;
	with ConditionalFormats.Add('1','K2') do
	begin
		BackColor := $ff;
		ApplyTo := EXG2ANTTLib.FormatApplyToEnum($2);
	end;
	MarkSearchColumn := False;
	DrawGridLines := EXG2ANTTLib.GridLinesEnum.exRowLines;
	with Columns do
	begin
		Add('Column 1');
		Add('Column 2');
		Add('Column 3');
	end;
	with Items do
	begin
		AddItem(Nil);
		AddItem(Nil);
		AddItem(Nil);
	end;
	EndUpdate();
end
1391
Is it possible to change the height for all items at once
with AxG2antt1 do
begin
	BeginUpdate();
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	Columns.Add('Items');
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[0] := True;
	end;
	EndUpdate();
	DefaultItemHeight := 12;
	Items.ItemHeight[0] := 12;
end
1390
Is it possible to include the weekday when displaying the date

with AxG2antt1 do
begin
	BeginUpdate();
	MarkSearchColumn := False;
	with Columns do
	begin
		Add('Tasks');
		with (Add('Start') as EXG2ANTTLib.Column) do
		begin
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(1);
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueFormat] := TObject(1);
			FormatColumn := 'value + ''<font ;6> ''  + (weekday(date(value)) case(0:''Sun'';1:''Mon'';2:''Tue'';3:''Wed'';4:''Thu'';5:''Fri'';6:''Sat''))';
		end;
		with (Add('End') as EXG2ANTTLib.Column) do
		begin
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(2);
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueFormat] := TObject(1);
			FormatColumn := 'value + ''<font ;6> ''  + (weekday(date(value)) case(0:''Sun'';1:''Mon'';2:''Tue'';3:''Wed'';4:''Thu'';5:''Fri'';6:''Sat''))';
		end;
	end;
	with Chart do
	begin
		FirstVisibleDate := '9/20/2006';
		AllowLinkBars := False;
		AllowCreateBar := EXG2ANTTLib.CreateBarEnum.exNoCreateBar;
		LevelCount := 2;
		PaneWidth[False] := 256;
		NonworkingDays := 0;
		FirstWeekDay := EXG2ANTTLib.WeekDayEnum.exMonday;
	end;
	with Items do
	begin
		AllowCellValueToItemBar := True;
		AddBar(AddItem('Task 1'),'Task','9/21/2006','9/24/2006',Nil,Nil);
		AddBar(AddItem('Task 2'),'Task','9/22/2006','9/25/2006',Nil,Nil);
		AddBar(AddItem('Task 3'),'Task','9/23/2006','9/26/2006',Nil,Nil);
	end;
	EndUpdate();
end
1389
I need my chart to display the end date with on day less. How can I do this (Method 1)

with AxG2antt1 do
begin
	BeginUpdate();
	MarkSearchColumn := False;
	with Columns do
	begin
		Add('Tasks');
		(Add('Start') as EXG2ANTTLib.Column).Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(1);
		with (Add('End') as EXG2ANTTLib.Column) do
		begin
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(2);
			FormatColumn := 'shortdate(date(value)-1)';
		end;
	end;
	with Chart do
	begin
		FirstVisibleDate := '9/20/2006';
		AllowLinkBars := False;
		AllowCreateBar := EXG2ANTTLib.CreateBarEnum.exNoCreateBar;
		LevelCount := 2;
		PaneWidth[False] := 196;
		NonworkingDays := 0;
	end;
	with Items do
	begin
		AllowCellValueToItemBar := True;
		AddBar(AddItem('Task 1'),'Task','9/21/2006','9/24/2006',Nil,Nil);
		AddBar(AddItem('Task 2'),'Task','9/22/2006','9/25/2006',Nil,Nil);
		AddBar(AddItem('Task 3'),'Task','9/23/2006','9/26/2006',Nil,Nil);
	end;
	EndUpdate();
end
1388
Is it possible to display my custom time-units

with AxG2antt1 do
begin
	with Chart do
	begin
		PaneWidth[False] := 0;
		LevelCount := 2;
		FirstVisibleDate := TObject(0);
		NonworkingDays := 0;
		with Level[0] do
		begin
			Unit := EXG2ANTTLib.UnitEnum.exDay;
			Count := 16;
			Alignment := EXG2ANTTLib.AlignmentEnum.CenterAlignment;
			Label := '<%i%>';
			FormatLabel := '''Half '' + (1 + (value/16) mod 2)';
		end;
		with Level[1] do
		begin
			Label := '<%i%>';
			FormatLabel := '1 + value mod 16';
			ReplaceLabel[2] := '<font ;10><B>Y';
		end;
		AdjustLevelsToBase := True;
		ScrollRange[EXG2ANTTLib.ScrollRangeEnum.exStartDate] := TObject(0);
		ScrollRange[EXG2ANTTLib.ScrollRangeEnum.exEndDate] := TObject(31);
	end;
end
1387
Is it possible to add new records and see them in the control's view using the DataSource

// AddItem event - Occurs after a new Item has been inserted to Items collection.
procedure TWinForm1.AxG2antt1_AddItem(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_AddItemEvent);
begin
	with AxG2antt1 do
	begin
		with Items do
		begin
			SelectItem[e.item] := True;
			EnsureVisibleItem(e.item);
		end;
		Edit(TObject(0));
	end
end;

// ButtonClick event - Occurs when user clicks on the cell's button.
procedure TWinForm1.AxG2antt1_ButtonClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ButtonClickEvent);
begin
	with AxG2antt1 do
	begin
		(DataSource as ADODB.Recordset).AddNew(Nil,Nil);
	end
end;

with AxG2antt1 do
begin
	rs := (ComObj.CreateComObject(ComObj.ProgIDToClassID('ADODB.Recordset')) as ADODB.Recordset);
	with rs.Fields do
	begin
		Append('Task',8,Nil,Nil,Nil);
		Append('Start',7,Nil,Nil,Nil);
		Append('End',7,Nil,Nil,Nil);
	end;
	rs.Open(Nil,Nil,Nil,Nil,Nil);
	DrawGridLines := EXG2ANTTLib.GridLinesEnum.exRowLines;
	DetectAddNew := True;
	DetectDelete := True;
	DataSource := (rs as ADODB.Recordset);
	with Items do
	begin
		LockedItemCount[EXG2ANTTLib.VAlignmentEnum.exTop] := 1;
		h := LockedItem[EXG2ANTTLib.VAlignmentEnum.exTop,0];
		ItemDivider[h] := 0;
		ItemHeight[h] := 22;
		CellValue[TObject(h),TObject(0)] := 'AddNew';
		CellHasButton[TObject(h),TObject(0)] := True;
		CellHAlignment[TObject(h),TObject(0)] := EXG2ANTTLib.AlignmentEnum.CenterAlignment;
	end;
end
1386
How can I limit the bars to scrolling range only
// CreateBar event - Fired when the user creates a new bar.
procedure TWinForm1.AxG2antt1_CreateBar(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_CreateBarEvent);
begin
	with AxG2antt1 do
	begin
		with Items do
		begin
			ItemBar[e.item,'newbar',EXG2ANTTLib.ItemBarPropertyEnum.exBarMinStart] := AxG2antt1.Chart.ScrollRange[EXG2ANTTLib.ScrollRangeEnum.exMinDate];
			ItemBar[e.item,'newbar',EXG2ANTTLib.ItemBarPropertyEnum.exBarMaxEnd] := AxG2antt1.Chart.ScrollRange[EXG2ANTTLib.ScrollRangeEnum.exMaxDate];
		end;
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	with Chart do
	begin
		LevelCount := 2;
		PaneWidth[False] := 56;
		ScrollRange[EXG2ANTTLib.ScrollRangeEnum.exStartDate] := '1/1/2001';
		ScrollRange[EXG2ANTTLib.ScrollRangeEnum.exEndDate] := '1/15/2001';
		FirstVisibleDate := '1/12/2001';
		AllowCreateBar := EXG2ANTTLib.CreateBarEnum.exCreateBarAuto;
	end;
	with Items do
	begin
		AddItem('Task 1');
		AddItem('Task 2');
		AddItem('Task 3');
	end;
	EndUpdate();
end
1385
How do I get the handle of the last added item
with AxG2antt1 do
begin
	Columns.Add('Def');
	with Items do
	begin
		AddItem(TObject(1));
		AddItem(TObject(2));
		OutputDebugString( ItemByIndex[ItemCount] );
	end;
end
1384
How can I set the charts date format to any other international Format then the US version. I would need "dd.mmm.yyyy" instead of "mmm.d.'yy"
with AxG2antt1 do
begin
	with Chart do
	begin
		PaneWidth[False] := 0;
		LevelCount := 2;
		with Level[0] do
		begin
			Label := '<%dd%>.<%mmm%>.<%yyyy%>';
			Unit := EXG2ANTTLib.UnitEnum.exWeek;
			Alignment := Integer(EXG2ANTTLib.AlignmentEnum.exHOutside) Or Integer(EXG2ANTTLib.AlignmentEnum.CenterAlignment);
		end;
	end;
end
1383
Is it possible to define the bar colors, and have the cumulative histogram showing the same colors

with AxG2antt1 do
begin
	BeginUpdate();
	SingleSel := False;
	with Chart do
	begin
		LevelCount := 2;
		AllowLinkBars := False;
		DrawGridLines := EXG2ANTTLib.GridLinesEnum.exAllLines;
		FirstVisibleDate := '12/24/2000';
		HistogramVisible := True;
		HistogramHeight := 64;
		PaneWidth[False] := 128;
		HistogramView := Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramNoGrouping) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramLeafItems) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramUnlockedItems) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramSelectedItems);
		with Bars.Item['Task'] do
		begin
			HistogramType := EXG2ANTTLib.HistogramTypeEnum.exHistCumulative;
			HistogramItems := 6;
			HistogramPattern := Pattern;
			HistogramCumulativeOriginalColorBars := EXG2ANTTLib.HistogramCumulativeOriginalColorBarsEnum.exKeepOriginalColor;
			OverlaidType := EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsOffset;
		end;
	end;
	Columns.Add('Column');
	with Items do
	begin
		h := AddItem('Project');
		ItemBold[h] := True;
		SelectableItem[h] := False;
		h1 := InsertItem(h,Nil,'Item 1');
		AddBar(h1,'Task','1/2/2001','1/4/2001',Nil,Nil);
		h1 := InsertItem(h,Nil,'Item 2');
		AddBar(h1,'Task','1/3/2001','1/5/2001',Nil,Nil);
		h1 := InsertItem(h,Nil,'Item 3');
		AddBar(h1,'Task','1/4/2001','1/6/2001',Nil,Nil);
		AddBar(h1,'Task','1/1/2001','1/3/2001','green',Nil);
		ItemBar[h1,'green',EXG2ANTTLib.ItemBarPropertyEnum.exBarColor] := TObject(65280);
		AddBar(h1,'Task','1/8/2001','1/10/2001','red',Nil);
		ItemBar[h1,'red',EXG2ANTTLib.ItemBarPropertyEnum.exBarColor] := TObject(255);
		ExpandItem[h] := True;
		SelectAll();
	end;
	EndUpdate();
end
1382
How can I hide the values shown in the legend when cumulative histogram is displayed

with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		HistogramVisible := True;
		HistogramHeight := 64;
		PaneWidth[False] := 128;
		HistogramView := Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramNoGrouping) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramLeafItems) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramUnlockedItems) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramCheckedItems);
		with Bars.Item['Task'] do
		begin
			HistogramPattern := EXG2ANTTLib.PatternEnum.exPatternSolid;
			HistogramType := EXG2ANTTLib.HistogramTypeEnum.exHistCumulative;
			HistogramItems := 6;
			HistogramRulerLinesColor := $80;
			HistogramBorderColor := $1;
			HistogramCumulativeShowLegend := 65535;
			HistogramCumulativeOriginalColorBars := EXG2ANTTLib.HistogramCumulativeOriginalColorBarsEnum.exChangeColor;
		end;
	end;
	with (Columns.Add('Column') as EXG2ANTTLib.Column) do
	begin
		Def[EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox] := TObject(True);
		PartialCheck := True;
	end;
	with Items do
	begin
		h := AddItem('Project 1');
		AddBar(InsertItem(h,Nil,'Item 1'),'Task','1/2/2001','1/4/2001',Nil,Nil);
		AddBar(InsertItem(h,Nil,'Item 2'),'Task','1/3/2001','1/5/2001',Nil,Nil);
		AddBar(InsertItem(h,Nil,'Item 3'),'Task','1/4/2001','1/6/2001',Nil,Nil);
		AddBar(InsertItem(h,Nil,'Item 4'),'Task','1/2/2001','1/8/2001',Nil,Nil);
		CellState[TObject(ItemByIndex[1]),TObject(0)] := 1;
		ExpandItem[h] := True;
	end;
	EndUpdate();
end
1381
Is it possible to define the bar colors, and have the cumulative histogram showing the same colors

with AxG2antt1 do
begin
	BeginUpdate();
	SelBackColor := BackColor;
	SelForeColor := ForeColor;
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		HistogramVisible := True;
		HistogramHeight := 64;
		PaneWidth[False] := 128;
		HistogramView := Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramNoGrouping) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramLeafItems) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramUnlockedItems) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramCheckedItems);
		with Bars.Item['Task'] do
		begin
			Color := $808080;
			HistogramType := EXG2ANTTLib.HistogramTypeEnum.exHistCumulative;
			HistogramItems := 6;
			HistogramRulerLinesColor := $80;
			HistogramBorderColor := $1;
			HistogramCumulativeColors := 2;
			HistogramCumulativeColor[0] := $ff0000;
			HistogramCumulativeColor[1] := $ff0000;
			HistogramCumulativeOriginalColorBars := EXG2ANTTLib.HistogramCumulativeOriginalColorBarsEnum.exChangeColor;
			HistogramPattern := Pattern;
			HistogramCumulativeShowLegend := 65535;
		end;
	end;
	with (Columns.Add('Column') as EXG2ANTTLib.Column) do
	begin
		Def[EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox] := TObject(True);
		PartialCheck := True;
	end;
	with Items do
	begin
		h := AddItem('Project 1');
		AddBar(InsertItem(h,Nil,'Item 1'),'Task','1/2/2001','1/4/2001',Nil,Nil);
		AddBar(InsertItem(h,Nil,'Item 2'),'Task','1/3/2001','1/5/2001',Nil,Nil);
		AddBar(InsertItem(h,Nil,'Item 3'),'Task','1/4/2001','1/6/2001',Nil,Nil);
		AddBar(InsertItem(h,Nil,'Item 4'),'Task','1/2/2001','1/8/2001',Nil,Nil);
		CellState[TObject(ItemByIndex[1]),TObject(0)] := 1;
		ExpandItem[h] := True;
	end;
	EndUpdate();
end
1380
Is it possible to show the non-working pattern over the bars

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Tasks');
	with Chart do
	begin
		NonworkingDaysPattern := EXG2ANTTLib.PatternEnum.exPatternBDiagonal;
		NonworkingDaysColor := $0;
		PaneWidth[False] := 40;
		FirstVisibleDate := '6/20/2005';
		HistogramVisible := True;
		HistogramHeight := 64;
		HistogramView := Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramBackground) Or Integer(EXG2ANTTLib.HistogramViewEnum.exHistogramAllItems);
		LevelCount := 2;
		with Bars do
		begin
			with Add('Empty') do
			begin
				Color := $0;
				Pattern := EXG2ANTTLib.PatternEnum.exPatternFDiagonal;
				Shape := EXG2ANTTLib.ShapeBarEnum.exShapeSolidFrameless;
			end;
			with Add('Task:Empty') do
			begin
				Shortcut := 'Task';
				HistogramItems := -5;
				HistogramCriticalValue := 3;
				HistogramType := EXG2ANTTLib.HistogramTypeEnum.exHistOverload;
				HistogramPattern := Pattern;
				Def[EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption] := '<%=%258%> working days bar';
				Def[EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
				Def[EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
			end;
		end;
		UnitWidthNonworking := -12;
		Level[1].FormatLabel := 'weekday(dvalue) in (0,6) ? `` : value';
	end;
	with Items do
	begin
		AddBar(AddItem('Task A'),'Task','6/23/2005','6/29/2005','',Nil);
		AddBar(AddItem('Task B'),'Task','6/24/2005','6/28/2005','',Nil);
	end;
	EndUpdate();
end
1379
I'm showing values from a ado recordset from sql 2005. When I try to edit a column with integers, it just skips back to the original numbers after pressing enter..., why
// AddItem event - Occurs after a new Item has been inserted to Items collection.
procedure TWinForm1.AxG2antt1_AddItem(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_AddItemEvent);
begin
	with AxG2antt1 do
	begin
		with Items do
		begin
			AddBar(e.item,'Task',CellValue[TObject(e.item),TObject(2)],CellValue[TObject(e.item),TObject(4)],Nil,Nil);
		end;
	end
end;

// Error event - Fired when an internal error occurs.
procedure TWinForm1.AxG2antt1_Error(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ErrorEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( e.error );
		OutputDebugString( e.description );
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		FirstVisibleDate := '8/3/1994';
		PaneWidth[False] := 256;
		LevelCount := 2;
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		FirstWeekDay := EXG2ANTTLib.WeekDayEnum.exMonday;
		OverviewVisible := EXG2ANTTLib.OverviewVisibleEnum.exOverviewShowAllVisible;
	end;
	ColumnAutoResize := False;
	ContinueColumnScroll := False;
	rs := (ComObj.CreateComObject(ComObj.ProgIDToClassID('ADOR.Recordset')) as ADODB.Recordset);
	with rs do
	begin
		Open('Orders','Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb',1,1,Nil);
	end;
	DataSource := (rs as ADODB.Recordset);
	Items.AllowCellValueToItemBar := True;
	Columns.Item[TObject(2)].Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(1);
	Columns.Item[TObject(4)].Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(2);
	EndUpdate();
end
1378
Is it possible to reduce the non-working parts of the control

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Tasks');
	with Chart do
	begin
		PaneWidth[False] := 40;
		FirstVisibleDate := '6/20/2005';
		HistogramVisible := True;
		HistogramHeight := 64;
		HistogramView := EXG2ANTTLib.HistogramViewEnum.exHistogramAllItems;
		LevelCount := 2;
		with Bars.Item['Task'] do
		begin
			HistogramType := EXG2ANTTLib.HistogramTypeEnum.exHistOverAllocation;
			HistogramPattern := Pattern;
		end;
		UnitWidthNonworking := -8;
		Level[1].FormatLabel := 'weekday(dvalue) in (0,6) ? `` : value';
	end;
	with Items do
	begin
		h := AddItem('Task A');
		AddBar(h,'Task','6/23/2005','6/29/2005','','4 working days bar');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanResize] := TObject(False);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarEffort] := TObject(4);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
		h := AddItem('Task B');
		AddBar(h,'Task','6/28/2005','6/30/2005','','2 working days bar');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanResize] := TObject(False);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarEffort] := TObject(2);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
	end;
	EndUpdate();
end
1377
I don't want to see the "schedule"/show "workload" in non-working days part of the histogram

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Tasks');
	with Chart do
	begin
		PaneWidth[False] := 40;
		FirstVisibleDate := '6/20/2005';
		HistogramVisible := True;
		HistogramHeight := 64;
		HistogramView := EXG2ANTTLib.HistogramViewEnum.exHistogramAllItems;
		LevelCount := 2;
		with Bars.Item['Task'] do
		begin
			HistogramType := EXG2ANTTLib.HistogramTypeEnum.exHistOverAllocation;
			HistogramPattern := Pattern;
		end;
		ShowNonworkingDates := False;
		ShowNonworkingUnits := False;
	end;
	with Items do
	begin
		h := AddItem('Task A');
		AddBar(h,'Task','6/23/2005','6/29/2005','','4 working days bar');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanResize] := TObject(False);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarEffort] := TObject(4);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
		h := AddItem('Task B');
		AddBar(h,'Task','6/28/2005','6/30/2005','','2 working days bar');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanResize] := TObject(False);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarEffort] := TObject(2);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
	end;
	EndUpdate();
end
1376
The control shows, and handles non-working days PERFECT, but how is it possible to reflect this in the Histogram. I don't want to "schedule"/show "workload" in non-working days...

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Tasks');
	with Chart do
	begin
		PaneWidth[False] := 40;
		FirstVisibleDate := '6/20/2005';
		HistogramVisible := True;
		HistogramHeight := 64;
		HistogramView := EXG2ANTTLib.HistogramViewEnum.exHistogramAllItems;
		LevelCount := 2;
		with Bars.Item['Task'] do
		begin
			HistogramType := EXG2ANTTLib.HistogramTypeEnum.exHistOverAllocation;
			HistogramPattern := Pattern;
		end;
	end;
	with Items do
	begin
		h := AddItem('Task A');
		AddBar(h,'Task','6/23/2005','6/29/2005','','4 working days bar');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanResize] := TObject(False);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarEffort] := TObject(4);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
		h := AddItem('Task B');
		AddBar(h,'Task','6/28/2005','6/30/2005','','2 working days bar');
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanResize] := TObject(False);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarEffort] := TObject(2);
		ItemBar[h,'',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
	end;
	EndUpdate();
end
1375
When I do select the button in the overview-zoom I want the scaling to change accordingly. Can I set different scales per selected zoom level

// OverviewZoom event - Occurs once the user selects a new time scale unit in the overview zoom area.
procedure TWinForm1.AxG2antt1_OverviewZoom(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( Chart.UnitScale );
	end
end;

with AxG2antt1 do
begin
	with Chart do
	begin
		PaneWidth[False] := 0;
		LevelCount := 2;
		OverviewVisible := EXG2ANTTLib.OverviewVisibleEnum.exOverviewShowAllVisible;
		AllowOverviewZoom := EXG2ANTTLib.OverviewZoomEnum.exAlwaysZoom;
		Label[EXG2ANTTLib.UnitEnum.exSecond] := '';
		Label[EXG2ANTTLib.UnitEnum.exYear] := '';
	end;
end
1374
How do I display Icons instead of text in the overview zoom area

with AxG2antt1 do
begin
	Images('gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTql' + 
	'Vq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0' + 
	'ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yN' + 
	'AOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=');
	with Chart do
	begin
		OverviewVisible := EXG2ANTTLib.OverviewVisibleEnum.exOverviewShowAllVisible;
		AllowOverviewZoom := EXG2ANTTLib.OverviewZoomEnum.exAlwaysZoom;
		Label[EXG2ANTTLib.UnitEnum.exSecond] := '';
		Label[EXG2ANTTLib.UnitEnum.exYear] := '';
		OutputDebugString( OverviewZoomCaption );
		OverviewZoomCaption := 'Year|½Year|¼Year|Month|Third|<img>1</img>|Day|Hour|Min|Sec';
	end;
end
1373
How do I get it to only display Min, Hour, Day, Week , Month, ie remove Sec and Year in the overview area
with AxG2antt1 do
begin
	with Chart do
	begin
		OverviewVisible := EXG2ANTTLib.OverviewVisibleEnum.exOverviewShowAllVisible;
		AllowOverviewZoom := EXG2ANTTLib.OverviewZoomEnum.exAlwaysZoom;
		Label[EXG2ANTTLib.UnitEnum.exSecond] := '';
		Label[EXG2ANTTLib.UnitEnum.exYear] := '';
	end;
end
1372
Is it possible to show quarter hours markers

with AxG2antt1 do
begin
	BeginUpdate();
	GridLineColor := Color.FromArgb(0,0,0);
	VisualAppearance.Add(3,'gBFLBCJwBAEHhEJAEGg4BdMIQAAYAQGKIYBkAKBQAGaAoDDUNw5QwAAwjSKkEwsACEIrjKCRShyCYZRhGcTAFBMIhkGoSZKlCIRVDCKYJDbKACSFKkNQ7AabZBgOQJVg' + 
	'OKovThKcIybQAASJCKRY7nUIIJA+SoDSRAbqhYIgASnKqLJAkACIJJAaRjHQdJxGKKMQANBghCZseKhWgkKIJUxAdLTWAAMQuaCoZ5icRAca2fJ+XzfeBYDgmAYNQbDc' + 
	'JhHCMMwXDaJZBiGJ4dimI4rR7JIDzDJ8cxbEKTZ5meg5boGRZNTrMQA0fQ9MynK6vahfOi7DpuaZnWrcMb2fYNZwrGq0bxoW58BwmP5/XrkNa4XgcVgmAUBA');
	HeaderHeight := 20;
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 0;
		LevelCount := 2;
		UnitScale := EXG2ANTTLib.UnitEnum.exHour;
		with Level[0] do
		begin
			Alignment := EXG2ANTTLib.AlignmentEnum.exHOutside;
			Label := '<%dddd%>, <%mmmm%> <b><%d%></b>, <%yyyy%>';
			DrawTickLines := EXG2ANTTLib.LevelLineEnum.exLevelSolidLine;
		end;
		with Level[1] do
		begin
			Label := '<%hh%>:00';
			BackColor := $3000000;
			DrawTickLines := EXG2ANTTLib.LevelLineEnum.exLevelSolidLine;
		end;
		DrawLevelSeparator := EXG2ANTTLib.LevelLineEnum.exLevelSolidLine;
		UnitWidth := 64;
		ResizeUnitScale := EXG2ANTTLib.UnitEnum.exMinute;
		ResizeUnitCount := 15;
	end;
	EndUpdate();
end
1371
How can I ensure or always show the labels on the chart part, when scrolling the chart to left or right
with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 0;
		LevelCount := 2;
		UnitWidth := 48;
		UnitScale := EXG2ANTTLib.UnitEnum.exHour;
		with Level[0] do
		begin
			Alignment := Integer(EXG2ANTTLib.AlignmentEnum.exHOutside) Or Integer(EXG2ANTTLib.AlignmentEnum.CenterAlignment);
			Label := '<%dddd%>, <%mmmm%> <b><%d%></b>, <%yyyy%>';
		end;
		Level[1].Label := '<%hh%>:00';
	end;
	EndUpdate();
end
1370
I associate the Start and End columns with bars, but some of them are not shown. What am I doing wrong
with AxG2antt1 do
begin
	BeginUpdate();
	MarkSearchColumn := False;
	Items.AllowCellValueToItemBar := True;
	with Chart do
	begin
		LevelCount := 2;
		FirstVisibleDate := '12/25/2000';
		PaneWidth[False] := 128;
	end;
	with (Columns.Add('Start') as EXG2ANTTLib.Column) do
	begin
		Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(1);
		Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey] := 'K1';
	end;
	with (Columns.Add('End') as EXG2ANTTLib.Column) do
	begin
		Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(2);
		Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey] := 'K1';
	end;
	with Items do
	begin
		AddBar(AddItem(Nil),'Task','1/1/2001','1/5/2001','K1',Nil);
		AddBar(AddItem(Nil),'Task','1/2/2001','1/6/2001','K1',Nil);
		AddBar(AddItem(Nil),'Task','1/3/2001','1/7/2001','????','????');
	end;
	EndUpdate();
end
1369
How can I implement OLE Drag and Drop operation
// OLEStartDrag event - Occurs when the OLEDrag method is called.
procedure TWinForm1.AxG2antt1_OLEStartDrag(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_OLEStartDragEvent);
begin
	// Data.SetData("your data to drag")
	with AxG2antt1 do
	begin
		e.allowedEffects := 2;
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	Columns.Add('Default');
	with Items do
	begin
		AddItem('Item 1');
		AddItem('Item 2');
		AddItem('Item 3');
		AddItem('Item 4');
		AddItem('Item 5');
	end;
	OLEDropMode := EXG2ANTTLib.exOLEDropModeEnum.exOLEDropManual;
	EndUpdate();
end
1368
I can not associate the bar's start and end properties with my start/end columns, only if the bar's key is empty or null. What can I do

// ButtonClick event - Occurs when user clicks on the cell's button.
procedure TWinForm1.AxG2antt1_ButtonClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ButtonClickEvent);
begin
	with AxG2antt1 do
	begin
		BeginUpdate();
		with Columns do
		begin
			Item['Tasks'].Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey] := 'B';
			Item['Start'].Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey] := 'B';
			Item['End'].Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey] := 'B';
		end;
		with Items do
		begin
			CellValue[TObject(e.item),TObject(1)] := 'B';
			ItemBar[0,'B',EXG2ANTTLib.ItemBarPropertyEnum.exBarColor] := TObject(0);
			ItemBar[0,'A',EXG2ANTTLib.ItemBarPropertyEnum.exBarColor] := TObject(16775408);
		end;
		EndUpdate();
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	with Columns do
	begin
		with (Add('Tasks') as EXG2ANTTLib.Column) do
		begin
			Width := 32;
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(3);
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey] := 'A';
		end;
		with (Add('Start') as EXG2ANTTLib.Column) do
		begin
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(1);
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey] := 'A';
			Editor.EditType := EXG2ANTTLib.EditTypeEnum.DateType;
		end;
		with (Add('End') as EXG2ANTTLib.Column) do
		begin
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(2);
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey] := 'A';
			Editor.EditType := EXG2ANTTLib.EditTypeEnum.DateType;
		end;
	end;
	with Chart do
	begin
		FirstVisibleDate := '9/20/2006';
		AllowLinkBars := True;
		AllowCreateBar := EXG2ANTTLib.CreateBarEnum.exNoCreateBar;
		LevelCount := 2;
		PaneWidth[False] := 196;
		with Bars.Item['Task'] do
		begin
			Pattern := EXG2ANTTLib.PatternEnum.exPatternBDiagonal;
			OverlaidType := Integer(EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStackAutoArrange) Or Integer(EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStack);
			Overlaid[EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsTransparent] := TObject(80);
		end;
	end;
	with Items do
	begin
		LockedItemCount[EXG2ANTTLib.VAlignmentEnum.exTop] := 1;
		h := LockedItem[EXG2ANTTLib.VAlignmentEnum.exTop,0];
		CellValue[TObject(h),TObject(0)] := 'Select';
		CellHasButton[TObject(h),TObject(0)] := True;
		CellMerge[TObject(h),TObject(1)] := TObject(2);
		CellValue[TObject(h),TObject(1)] := 'A';
		CellEditor[TObject(h),TObject(1)].EditType := EXG2ANTTLib.EditTypeEnum.EditType;
	end;
	with Items do
	begin
		AllowCellValueToItemBar := True;
		h := AddItem('Task 1');
		AddBar(h,'Task','9/21/2006','9/24/2006','A','A');
		AddBar(h,'Task','9/25/2006','9/28/2006','B','B');
		ItemBar[h,'B',EXG2ANTTLib.ItemBarPropertyEnum.exBarColor] := TObject(16775408);
		h := AddItem('Task 2');
		AddBar(h,'Task','9/22/2006','9/25/2006','A','A');
		AddBar(h,'Task','9/26/2006','9/29/2006','B','B');
		ItemBar[h,'B',EXG2ANTTLib.ItemBarPropertyEnum.exBarColor] := TObject(16775408);
	end;
	EndUpdate();
end
1367
How can I determine the order of the events
// AddLink event - Occurs when the user links two bars using the mouse.
procedure TWinForm1.AxG2antt1_AddLink(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_AddLinkEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'AddLink' );
		OutputDebugString( e.linkKey );
	end
end;

// AfterExpandItem event - Fired after an item is expanded (collapsed).
procedure TWinForm1.AxG2antt1_AfterExpandItem(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_AfterExpandItemEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'AfterExpandItem' );
		OutputDebugString( e.item );
	end
end;

// AllowLink event - Notifies at runtime when a link between two bars is possible.
procedure TWinForm1.AxG2antt1_AllowLink(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_AllowLinkEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'AllowLink' );
		OutputDebugString( e.startItem );
		OutputDebugString( e.startBarKey );
		OutputDebugString( e.endItem );
		OutputDebugString( e.endBarKey );
		OutputDebugString( e.linkKey );
	end
end;

// AnchorClick event - Occurs when an anchor element is clicked.
procedure TWinForm1.AxG2antt1_AnchorClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_AnchorClickEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'AnchorClick' );
		OutputDebugString( e.anchorID );
		OutputDebugString( e.options );
	end
end;

// BarParentChange event - Occurs just before moving a bar from current item to another item.
procedure TWinForm1.AxG2antt1_BarParentChange(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_BarParentChangeEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'BarParentChange' );
		OutputDebugString( e.item );
		OutputDebugString( e.key );
		OutputDebugString( e.newItem );
	end
end;

// BarResize event - Occurs when a bar is moved or resized.
procedure TWinForm1.AxG2antt1_BarResize(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_BarResizeEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'BarResize' );
		OutputDebugString( e.item );
		OutputDebugString( e.key );
	end
end;

// BarResizing event - Occurs when a bar is moving or resizing.
procedure TWinForm1.AxG2antt1_BarResizing(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_BarResizingEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'BarResizing' );
		OutputDebugString( e.item );
		OutputDebugString( e.key );
	end
end;

// BeforeExpandItem event - Fired before an item is about to be expanded (collapsed).
procedure TWinForm1.AxG2antt1_BeforeExpandItem(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_BeforeExpandItemEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'BeforeExpandItem' );
		OutputDebugString( e.item );
	end
end;

// ButtonClick event - Occurs when user clicks on the cell's button.
procedure TWinForm1.AxG2antt1_ButtonClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ButtonClickEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'ButtonClick' );
		OutputDebugString( e.item );
		OutputDebugString( e.colIndex );
		OutputDebugString( e.key );
	end
end;

// CellImageClick event - Fired after the user clicks on the image's cell area.
procedure TWinForm1.AxG2antt1_CellImageClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_CellImageClickEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'CellImageClick' );
		OutputDebugString( e.item );
		OutputDebugString( e.colIndex );
	end
end;

// CellStateChanged event - Fired after cell's state has been changed.
procedure TWinForm1.AxG2antt1_CellStateChanged(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_CellStateChangedEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'CellStateChanged' );
		OutputDebugString( e.item );
		OutputDebugString( e.colIndex );
	end
end;

// Change event - Occurs when the user changes the cell's content.
procedure TWinForm1.AxG2antt1_Change(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ChangeEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'Change' );
		OutputDebugString( e.item );
		OutputDebugString( e.colIndex );
		OutputDebugString( e.newValue );
	end
end;

// ChartEndChanging event - Occurs after the chart has been changed.
procedure TWinForm1.AxG2antt1_ChartEndChanging(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ChartEndChangingEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'ChartEndChanging' );
		OutputDebugString( e.operation );
	end
end;

// ChartSelectionChanged event - Occurs when the user selects objects in the chart area.
procedure TWinForm1.AxG2antt1_ChartSelectionChanged(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'ChartSelectionChanged' );
	end
end;

// ChartStartChanging event - Occurs when the chart is about to be changed.
procedure TWinForm1.AxG2antt1_ChartStartChanging(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ChartStartChangingEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'ChartStartChanging' );
		OutputDebugString( e.operation );
	end
end;

// Click event - Occurs when the user presses and then releases the left mouse button over the tree control.
procedure TWinForm1.AxG2antt1_ClickEvent(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'Click' );
	end
end;

// ColumnClick event - Fired after the user clicks on column's header.
procedure TWinForm1.AxG2antt1_ColumnClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ColumnClickEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'ColumnClick' );
	end
end;

// CreateBar event - Fired when the user creates a new bar.
procedure TWinForm1.AxG2antt1_CreateBar(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_CreateBarEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'CreateBar' );
		OutputDebugString( e.item );
		OutputDebugString( e.dateStart );
		OutputDebugString( e.dateEnd );
	end
end;

// DateChange event - Occurs when the first visible date is changed.
procedure TWinForm1.AxG2antt1_DateChange(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'DateChange' );
	end
end;

// DblClick event - Occurs when the user dblclk the left mouse button over an object.
procedure TWinForm1.AxG2antt1_DblClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_DblClickEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'DblClick' );
		OutputDebugString( e.shift );
		OutputDebugString( e.x );
		OutputDebugString( e.y );
		Edit(Nil);
	end
end;

// Edit event - Occurs just before editing the focused cell.
procedure TWinForm1.AxG2antt1_EditEvent(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_EditEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'Edit' );
		OutputDebugString( e.item );
		OutputDebugString( e.colIndex );
	end
end;

// EditClose event - Occurs when the edit operation ends.
procedure TWinForm1.AxG2antt1_EditCloseEvent(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'EditClose' );
	end
end;

// EditOpen event - Occurs when the edit operation starts.
procedure TWinForm1.AxG2antt1_EditOpen(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'EditOpen' );
	end
end;

// FilterChange event - Occurs when the filter was changed.
procedure TWinForm1.AxG2antt1_FilterChange(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'FilterChange' );
	end
end;

// FilterChanging event - Notifies your application that the filter is about to change.
procedure TWinForm1.AxG2antt1_FilterChanging(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'FilterChanging' );
	end
end;

// FocusChanged event - Occurs when a cell gets the focus.
procedure TWinForm1.AxG2antt1_FocusChanged(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'FocusChanged' );
	end
end;

// InsideZoom event - Notifies your application that a date is about to be magnified.
procedure TWinForm1.AxG2antt1_InsideZoom(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_InsideZoomEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'InsideZoom' );
		OutputDebugString( e.dateTime );
	end
end;

// KeyDown event - Occurs when the user presses a key while an object has the focus.
procedure TWinForm1.AxG2antt1_KeyDownEvent(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_KeyDownEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'KeyDown' );
		OutputDebugString( e.keyCode );
		OutputDebugString( e.shift );
	end
end;

// KeyPress event - Occurs when the user presses and releases an ANSI key.
procedure TWinForm1.AxG2antt1_KeyPressEvent(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_KeyPressEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'KeyPress' );
		OutputDebugString( e.keyAscii );
	end
end;

// KeyUp event - Occurs when the user releases a key while an object has the focus.
procedure TWinForm1.AxG2antt1_KeyUpEvent(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_KeyUpEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'KeyUp' );
		OutputDebugString( e.keyCode );
		OutputDebugString( e.shift );
	end
end;

// LayoutChanged event - Occurs when column's position or column's size is changed.
procedure TWinForm1.AxG2antt1_LayoutChanged(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'LayoutChanged' );
	end
end;

// MouseDown event - Occurs when the user presses a mouse button.
procedure TWinForm1.AxG2antt1_MouseDownEvent(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_MouseDownEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'MouseDown' );
		OutputDebugString( e.button );
		OutputDebugString( e.shift );
		OutputDebugString( e.x );
		OutputDebugString( e.y );
	end
end;

// MouseMove event - Occurs when the user moves the mouse.
procedure TWinForm1.AxG2antt1_MouseMoveEvent(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_MouseMoveEvent);
begin
end;

// MouseUp event - Occurs when the user releases a mouse button.
procedure TWinForm1.AxG2antt1_MouseUpEvent(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_MouseUpEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'MouseUp' );
		OutputDebugString( e.button );
		OutputDebugString( e.shift );
		OutputDebugString( e.x );
		OutputDebugString( e.y );
	end
end;

// OffsetChanged event - Occurs when the scroll position has been changed.
procedure TWinForm1.AxG2antt1_OffsetChanged(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_OffsetChangedEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'OffsetChanged' );
		OutputDebugString( e.horizontal );
		OutputDebugString( e.newVal );
	end
end;

// OversizeChanged event - Occurs when the right range of the scroll has been changed.
procedure TWinForm1.AxG2antt1_OversizeChanged(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_OversizeChangedEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'OversizeChanged' );
		OutputDebugString( e.horizontal );
		OutputDebugString( e.newVal );
	end
end;

// OverviewZoom event - Occurs once the user selects a new time scale unit in the overview zoom area.
procedure TWinForm1.AxG2antt1_OverviewZoom(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'OverviewZoom' );
	end
end;

// RClick event - Fired when right mouse button is clicked
procedure TWinForm1.AxG2antt1_RClick(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'RClick' );
	end
end;

// ScrollButtonClick event - Occurs when the user clicks a button in the scrollbar.
procedure TWinForm1.AxG2antt1_ScrollButtonClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ScrollButtonClickEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'ScrollButtonClick' );
		OutputDebugString( e.scrollBar );
		OutputDebugString( e.scrollPart );
	end
end;

// SelectionChanged event - Fired after a new item has been selected.
procedure TWinForm1.AxG2antt1_SelectionChanged(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'SelectionChanged' );
	end
end;

// Sort event - Fired when the control sorts a column.
procedure TWinForm1.AxG2antt1_Sort(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'Sort' );
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	Images('gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTql' + 
	'Vq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0' + 
	'ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yN' + 
	'AOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=');
	DrawGridLines := EXG2ANTTLib.GridLinesEnum.exAllLines;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	GridLineStyle := EXG2ANTTLib.GridLinesStyleEnum.exGridLinesHDash;
	AutoEdit := False;
	ExpandOnDblClick := False;
	with Chart do
	begin
		AllowInsideZoom := True;
		OverviewVisible := EXG2ANTTLib.OverviewVisibleEnum.exOverviewShowAllVisible;
		AllowOverviewZoom := EXG2ANTTLib.OverviewZoomEnum.exAlwaysZoom;
		PaneWidth[False] := 128;
		FirstVisibleDate := '1/1/2001';
		DrawGridLines := EXG2ANTTLib.GridLinesEnum.exAllLines;
		GridLineStyle := Integer(EXG2ANTTLib.GridLinesStyleEnum.exGridLinesVSolid) Or Integer(EXG2ANTTLib.GridLinesStyleEnum.exGridLinesHDash);
		LevelCount := 2;
		Level[0].DrawGridLines := True;
		Bars.Item['Task'].Pattern := EXG2ANTTLib.PatternEnum.exPatternSolid;
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		Label[EXG2ANTTLib.UnitEnum.exSecond] := '';
		Label[EXG2ANTTLib.UnitEnum.exMinute] := '';
		Label[EXG2ANTTLib.UnitEnum.exHour] := '';
	end;
	with Columns do
	begin
		with (Add('Column') as EXG2ANTTLib.Column) do
		begin
			DisplayFilterButton := True;
			Def[EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox] := TObject(True);
			Editor.EditType := EXG2ANTTLib.EditTypeEnum.EditType;
		end;
		with (Add('Button') as EXG2ANTTLib.Column) do
		begin
			AllowSizing := False;
			Width := 18;
			Def[EXG2ANTTLib.DefColumnEnum.exCellHasButton] := TObject(True);
		end;
	end;
	with Items do
	begin
		h := AddItem('parent');
		CellImage[TObject(h),TObject(0)] := 1;
		AddBar(h,'Task','1/2/2001','1/5/2001','A','<a>A</a>');
		ItemBar[h,'A',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'A',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanMoveToAnother] := TObject(True);
		ItemBar[h,'A',EXG2ANTTLib.ItemBarPropertyEnum.exBarToolTip] := 'This is a bit of text that should be shown when cursor hovers the bar';
		AddBar(h,'Task','1/8/2001','1/15/2001','B','<a>B</a>');
		ItemBar[h,'B',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'B',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanMoveToAnother] := TObject(True);
		InsertItem(h,'','child');
		ExpandItem[h] := True;
	end;
	EndUpdate();
end
1366
How can I change the chart's horizontal grid lines
with AxG2antt1 do
begin
	BeginUpdate();
	DrawGridLines := EXG2ANTTLib.GridLinesEnum.exAllLines;
	GridLineStyle := EXG2ANTTLib.GridLinesStyleEnum.exGridLinesHDash;
	with Chart do
	begin
		PaneWidth[False] := 48;
		FirstVisibleDate := '1/1/2001';
		DrawGridLines := EXG2ANTTLib.GridLinesEnum.exAllLines;
		GridLineStyle := Integer(EXG2ANTTLib.GridLinesStyleEnum.exGridLinesVSolid) Or Integer(EXG2ANTTLib.GridLinesStyleEnum.exGridLinesHDash);
		LevelCount := 2;
		Level[0].DrawGridLines := True;
		Bars.Item['Task'].Pattern := EXG2ANTTLib.PatternEnum.exPatternSolid;
	end;
	Columns.Add('Column');
	with Items do
	begin
		h := AddItem('Item 1');
		AddBar(h,'Task','1/2/2001','1/5/2001','A',Nil);
		AddBar(h,'Task','1/8/2001','1/15/2001','B',Nil);
	end;
	EndUpdate();
end
1365
Is there any way to determine whether the ADO operations fails
// AddItem event - Occurs after a new Item has been inserted to Items collection.
procedure TWinForm1.AxG2antt1_AddItem(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_AddItemEvent);
begin
	with AxG2antt1 do
	begin
		with Items do
		begin
			AddBar(e.item,'Task',CellValue[TObject(e.item),TObject(2)],CellValue[TObject(e.item),TObject(4)],Nil,Nil);
		end;
	end
end;

// Error event - Fired when an internal error occurs.
procedure TWinForm1.AxG2antt1_Error(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ErrorEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( e.error );
		OutputDebugString( e.description );
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		FirstVisibleDate := '8/3/1994';
		PaneWidth[False] := 256;
		LevelCount := 2;
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		FirstWeekDay := EXG2ANTTLib.WeekDayEnum.exMonday;
		OverviewVisible := EXG2ANTTLib.OverviewVisibleEnum.exOverviewShowAllVisible;
	end;
	ColumnAutoResize := False;
	ContinueColumnScroll := False;
	rs := (ComObj.CreateComObject(ComObj.ProgIDToClassID('ADOR.Recordset')) as ADODB.Recordset);
	with rs do
	begin
		Open('Orders','Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb',1,1,Nil);
	end;
	DataSource := (rs as ADODB.Recordset);
	Items.AllowCellValueToItemBar := True;
	Columns.Item[TObject(2)].Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(1);
	Columns.Item[TObject(4)].Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(2);
	EndUpdate();
end
1364
Is it possible to select a column instead sorting it
// ColumnClick event - Fired after the user clicks on column's header.
procedure TWinForm1.AxG2antt1_ColumnClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ColumnClickEvent);
begin
	// Column.Selected = True
	with AxG2antt1 do
	begin
		BeginUpdate();
		Columns.Item[TObject(0)].Selected := False;
		Columns.Item[TObject(1)].Selected := False;
		Items.SelectAll();
		EndUpdate();
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	MarkSearchColumn := False;
	ShowFocusRect := False;
	SingleSel := False;
	FullRowSelect := EXG2ANTTLib.CellSelectEnum.exRectSel;
	SortOnClick := EXG2ANTTLib.SortOnClickEnum.exNoSort;
	with Columns do
	begin
		Add('Column1');
		Add('Column2');
	end;
	with Items do
	begin
		CellValue[TObject(AddItem('One')),TObject(1)] := 'Three';
		CellValue[TObject(AddItem('Two')),TObject(1)] := 'Four';
		SelectAll();
	end;
	EndUpdate();
end
1363
I am using the exRectSel, and clicking the first column, has no effect, instead if I click other it works as it should
with AxG2antt1 do
begin
	BeginUpdate();
	SearchColumnIndex := -1;
	FullRowSelect := EXG2ANTTLib.CellSelectEnum.exRectSel;
	ShowFocusRect := False;
	MarkSearchColumn := False;
	with Columns do
	begin
		Add('Column1');
		Add('Column2');
	end;
	with Items do
	begin
		CellValue[TObject(AddItem(TObject(1))),TObject(1)] := TObject(2);
		CellValue[TObject(AddItem(TObject(3))),TObject(1)] := TObject(4);
		CellValue[TObject(AddItem(TObject(5))),TObject(1)] := TObject(6);
	end;
	EndUpdate();
end
1362
Is it possible to display empty strings for 0 values
with AxG2antt1 do
begin
	with (Columns.Add('Currency') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := 'dbl(value) ? currency(dbl(value)) : ``';
		with Editor do
		begin
			EditType := EXG2ANTTLib.EditTypeEnum.EditType;
			Numeric := EXG2ANTTLib.NumericEnum.exFloat;
		end;
	end;
	with Items do
	begin
		AddItem(TObject(1.23));
		AddItem(TObject(2.34));
		AddItem(TObject(0));
		AddItem(TObject(10000.99));
	end;
end
1361
Is it possible to display empty strings for 0 values
with AxG2antt1 do
begin
	Columns.Add('Number');
	(Columns.Add('Currency') as EXG2ANTTLib.Column).ComputedField := '%0 ? currency(%0) : ``';
	with Items do
	begin
		AddItem(TObject(1.23));
		AddItem(TObject(2.34));
		AddItem(TObject(0));
		AddItem(TObject(10000.99));
	end;
end
1360
How can I hide a date from the chart view, when I display hours instead days

with AxG2antt1 do
begin
	BeginUpdate();
	HeaderHeight := 32;
	with Chart do
	begin
		FirstVisibleDate := '6/8/2011';
		AdjustLevelsToBase := True;
		PaneWidth[False] := 0;
		LevelCount := 2;
		AllowInsideZoom := True;
		with Level[0] do
		begin
			Alignment := EXG2ANTTLib.AlignmentEnum.CenterAlignment;
			Label := '<b><%d%>-<%mmm%>-<%yyyy%>';
			Unit := EXG2ANTTLib.UnitEnum.exDay;
		end;
		with Level[1] do
		begin
			Label := '<%h%>';
			Count := 8;
			Unit := EXG2ANTTLib.UnitEnum.exHour;
			FormatLabel := 'date(int(dvalue)) case (#06/08/2011# : (int(value) case ( 0 : ''Shift <b>1</b><br>23/20''; 8 : ''Shift <b>2</b><br>38/30'' ; 16 : ''S' + 
	'hift <b>3</b><br>24/24'' ) ) ; #06/09/2011# : (int(value) case ( 0 : ''Shift <b>1</b><br>15/20''; 8 : ''Shift <b>2</b><br>30/32'' ; 1' + 
	'6 : ''Shift <b>3</b><br>26/24'' ) ) )';
		end;
		UnitWidth := 64;
		NonworkingDays := 0;
		AllowInsideZoom := True;
		DefaultInsideZoomFormat.InsideUnit := EXG2ANTTLib.UnitEnum.exMinute;
		AllowResizeInsideZoom := False;
		InsideZoomOnDblClick := False;
		with InsideZooms do
		begin
			SplitBaseLevel := False;
			DefaultWidth := 0;
		end;
		with InsideZooms do
		begin
			Add('6/9/2011 8:00:00 AM');
			Add('6/9/2011 4:00:00 PM');
		end;
	end;
	EndUpdate();
end
1359
I’ve created a skin (EBN) for the bars of my chart, with rounded top corners. The problem, is that these rounded corners are applied also at beginning and the end of the non working units. Is it possible to show a different picture/skin for the non-working part of the bars

with AxG2antt1 do
begin
	BeginUpdate();
	VisualAppearance.Add(1,'c:\exontrol\images\normal.ebn');
	VisualAppearance.Add(2,'c:\exontrol\images\pushed.ebn');
	Columns.Add('Task');
	Chart.PaneWidth[False] := 128;
	with Chart.Bars do
	begin
		Item['Task'].Color := $1000000;
		Item['Split'].Color := $2000000;
		Add('Task:Split').Shortcut := 'TS';
	end;
	Chart.FirstVisibleDate := '1/1/2001';
	with Items do
	begin
		AddBar(AddItem('Task'),'TS','1/2/2001','1/16/2001',Nil,Nil);
	end;
	EndUpdate();
end
1358
How do I display the names of the tasks on bars but not in the middle of the bar (left or right)

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Tasks');
	with Chart do
	begin
		FirstVisibleDate := '12/27/2000';
		PaneWidth[False] := 128;
		with Bars.Item['Task'] do
		begin
			Pattern := EXG2ANTTLib.PatternEnum.exPatternDot;
			Height := 15;
		end;
	end;
	with Items do
	begin
		h := AddItem('Task 1');
		AddBar(h,'Task','1/3/2001','1/8/2001','K1','<b>to do</b> ');
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(2);
		h := AddItem('Task 2');
		AddBar(h,'Task','1/3/2001','1/8/2001','K2','<b>to do</b>');
		ItemBar[h,'K2',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		h := AddItem('Task 3');
		AddBar(h,'Task','1/3/2001','1/8/2001','K1',' <b>to do</b>');
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(0);
		h := AddItem('Task 4');
		AddBar(h,'Task','1/3/2001','1/8/2001','K2','<b>to do</b>');
		ItemBar[h,'K2',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(16);
	end;
	EndUpdate();
end
1357
How can I get the list of items as they are displayed
with AxG2antt1 do
begin
	BeginUpdate();
	BackColorAlternate := Color.FromArgb(240,240,240);
	Columns.Add('Names');
	with Items do
	begin
		AddItem('Mantel');
		AddItem('Mechanik');
		AddItem('Motor');
		AddItem('Murks');
		AddItem('Märchen');
		AddItem('Möhren');
		AddItem('Mühle');
	end;
	Columns.Item[TObject(0)].SortOrder := EXG2ANTTLib.SortOrderEnum.SortAscending;
	EndUpdate();
	OutputDebugString( GetItems(TObject(1)) );
end
1356
How can I disable the left and right arrows to move to next cell while editing
with AxG2antt1 do
begin
	var_Editor := (Columns.Add('Edit') as EXG2ANTTLib.Column).Editor;
	with var_Editor do
	begin
		EditType := EXG2ANTTLib.EditTypeEnum.EditType;
		Option[EXG2ANTTLib.EditorOptionEnum.exLeftArrow] := TObject(0);
		Option[EXG2ANTTLib.EditorOptionEnum.exRightArrow] := TObject(0);
	end;
	with Items do
	begin
		AddItem('Cell 1');
		AddItem('Cell 2');
		AddItem('Cell 3');
	end;
end
1355
Is it possible to define a bar that is treated as a non-working hour so user can move it at runtime

with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		LevelCount := 2;
		PaneWidth[False] := 48;
		AllowNonworkingBars := True;
		Bars.Add('Task:Split').Shortcut := 'Task';
		UnitScale := EXG2ANTTLib.UnitEnum.exHour;
		Level[1].Label := '<font ;4><%hh%>';
		UnitWidth := 12;
		NonworkingDaysPattern := EXG2ANTTLib.PatternEnum.exPatternBDiagonal;
		NonworkingDays := 0;
	end;
	Columns.Add('Tasks');
	with Items do
	begin
		h := AddItem('Machine');
		ItemNonworkingUnits[h,TObject(False)] := '0';
		AddBar(h,'','1/1/2001 9:00:00 AM','1/1/2001 11:00:00 AM','A','pause');
		ItemBar[h,'A',EXG2ANTTLib.ItemBarPropertyEnum.exBarTreatAsNonworking] := TObject(True);
		AddBar(h,'Task','1/1/2001 12:00:00 PM','1/1/2001 5:00:00 PM','Z',Nil);
		ItemBar[h,'Z',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
	end;
	EndUpdate();
end
1354
Is it possible to customize the chart's header so I can display shift and other values

with AxG2antt1 do
begin
	BeginUpdate();
	HeaderHeight := 32;
	with Chart do
	begin
		FirstVisibleDate := '6/8/2011';
		AdjustLevelsToBase := True;
		PaneWidth[False] := 0;
		LevelCount := 2;
		with Level[0] do
		begin
			Alignment := EXG2ANTTLib.AlignmentEnum.CenterAlignment;
			Label := '<b><%d%> - <%mmmm%> - <%yyyy%>';
			Unit := EXG2ANTTLib.UnitEnum.exDay;
		end;
		with Level[1] do
		begin
			Label := '<%h%>';
			Count := 8;
			Unit := EXG2ANTTLib.UnitEnum.exHour;
			FormatLabel := 'date(int(dvalue)) case (#06/08/2011# : (int(value) case ( 0 : ''Shift <b>1</b><br>23/20''; 8 : ''Shift <b>2</b><br>38/30'' ; 16 : ''S' + 
	'hift <b>3</b><br>24/24'' ) ) ; #06/09/2011# : (int(value) case ( 0 : ''Shift <b>1</b><br>15/20''; 8 : ''Shift <b>2</b><br>30/32'' ; 1' + 
	'6 : ''Shift <b>3</b><br>26/24'' ) ) )';
		end;
		UnitWidth := 64;
		NonworkingDays := 0;
	end;
	EndUpdate();
end
1353
How can I change both start and end dates of the bar
with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Tasks');
	with Chart do
	begin
		PaneWidth[False] := 64;
		FirstVisibleDate := '6/19/2005';
	end;
	with Items do
	begin
		h := AddItem('Test');
		AddBar(h,'Task','6/22/2005','6/27/2005','t1',Nil);
		AddBar(h,ItemBar[h,'t1',EXG2ANTTLib.ItemBarPropertyEnum.exBarName],'6/21/2005','6/22/2005','t1',Nil);
	end;
	EndUpdate();
end
1352
Is it possible to add new rows, as I type like in Excel
// EditClose event - Occurs when the edit operation ends.
procedure TWinForm1.AxG2antt1_EditCloseEvent(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		Items.AddItem('');
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	AutoEdit := True;
	(Columns.Add('Default') as EXG2ANTTLib.Column).Editor.EditType := EXG2ANTTLib.EditTypeEnum.EditType;
	FullRowSelect := EXG2ANTTLib.CellSelectEnum.exColumnSel;
	Items.AddItem('');
	DrawGridLines := EXG2ANTTLib.GridLinesEnum.exAllLines;
	ScrollBars := EXG2ANTTLib.ScrollBarsEnum.exDisableBoth;
	EndUpdate();
end
1351
How do I load bars from my table/database
// AddItem event - Occurs after a new Item has been inserted to Items collection.
procedure TWinForm1.AxG2antt1_AddItem(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_AddItemEvent);
begin
	with AxG2antt1 do
	begin
		with Items do
		begin
			AddBar(e.item,'Task',CellValue[TObject(e.item),TObject(2)],CellValue[TObject(e.item),TObject(4)],Nil,Nil);
		end;
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		FirstVisibleDate := '8/3/1994';
		PaneWidth[False] := 256;
		LevelCount := 2;
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		FirstWeekDay := EXG2ANTTLib.WeekDayEnum.exMonday;
		OverviewVisible := EXG2ANTTLib.OverviewVisibleEnum.exOverviewShowAllVisible;
	end;
	ColumnAutoResize := False;
	ContinueColumnScroll := False;
	rs := (ComObj.CreateComObject(ComObj.ProgIDToClassID('ADOR.Recordset')) as ADODB.Recordset);
	with rs do
	begin
		Open('Orders','Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb',3,3,Nil);
	end;
	DataSource := (rs as ADODB.Recordset);
	Items.AllowCellValueToItemBar := True;
	Columns.Item[TObject(2)].Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(1);
	Columns.Item[TObject(4)].Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(2);
	EndUpdate();
end
1350
Is posible to reduce the size of the picture to be shown in the bar's caption

with AxG2antt1 do
begin
	BeginUpdate();
	set_HTMLPicture('pic1','c:\exontrol\images\zipdisk.gif');
	Columns.Add('Task');
	ScrollBySingleLine := True;
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 78;
	end;
	with Items do
	begin
		h := AddItem('Default-Size');
		ItemHeight[h] := 48;
		AddBar(h,'Task','1/2/2001','1/6/2001','K1','<img>pic1</img>');
		h := AddItem('Custom-Size');
		AddBar(h,'Task','1/2/2001','1/6/2001','K2','<img>pic1:18</img>');
	end;
	EndUpdate();
end
1349
Is posible to reduce the size of the picture to be shown in the column's caption
with AxG2antt1 do
begin
	BeginUpdate();
	set_HTMLPicture('pic1','c:\exontrol\images\zipdisk.gif');
	HeaderHeight := 48;
	(Columns.Add('DefaultSize') as EXG2ANTTLib.Column).HTMLCaption := 'Default-Size <img>pic1</img> Picture';
	(Columns.Add('CustomSize') as EXG2ANTTLib.Column).HTMLCaption := 'Custom-Size <img>pic1:16</img> Picture';
	EndUpdate();
end
1348
Is it possible to display the selected dates using a solid color instead vertical lines

with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		PaneWidth[False] := 128;
		FirstVisibleDate := '1/1/2008';
		MarkTodayColor := BackColor;
		LevelCount := 2;
		MarkSelectDateColor := $7fcbc0ff;
		SelectLevel := 1;
		SelectDate['1/8/2008'] := True;
		SelectDate['1/9/2008'] := True;
		SelectDate['1/10/2008'] := True;
	end;
	DefaultItemHeight := 72;
	Columns.Add('Default');
	with Items do
	begin
		AddBar(AddItem(''),'','1/7/2008','1/12/2008','','<b>MarkSelectDateColor(32)</b><br>should be <font ;11><i>0x7F000000 + RGB(rr,gg,bb)</i></font><br> or in the format as: <font ;1' + 
	'1><i>0x7FBBGGRR</i></font>, <br>where BB is the hexa value for Blue, <br>GG for grean and so on.');
	end;
	EndUpdate();
end
1347
How can I show the cells using a different background color based on the condition I have
with AxG2antt1 do
begin
	BeginUpdate();
	SelBackMode := EXG2ANTTLib.BackModeEnum.exTransparent;
	ShowFocusRect := False;
	with ConditionalFormats do
	begin
		with Add('dbl(%1)-dbl(%0) = 1',Nil) do
		begin
			BackColor := $ff;
			ApplyTo := EXG2ANTTLib.FormatApplyToEnum($1);
		end;
		with Add('dbl(%0)-dbl(%1) = 3',Nil) do
		begin
			BackColor := $ffff;
			ApplyTo := EXG2ANTTLib.FormatApplyToEnum.exFormatToColumns;
		end;
		with Add('dbl(%1)-dbl(%0) = 4',Nil) do
		begin
			ForeColor := $808080;
			Bold := True;
			ApplyTo := EXG2ANTTLib.FormatApplyToEnum.exFormatToItems;
		end;
	end;
	with Columns do
	begin
		(Add('C1') as EXG2ANTTLib.Column).Width := 8;
		(Add('C2') as EXG2ANTTLib.Column).Width := 8;
		Add('');
	end;
	Chart.PaneWidth[True] := 0;
	with Items do
	begin
		CellValue[TObject(AddItem(TObject(2))),TObject(1)] := TObject(3);
		CellValue[TObject(AddItem(TObject(5))),TObject(1)] := TObject(2);
		CellValue[TObject(AddItem(TObject(5))),TObject(1)] := TObject(6);
		CellValue[TObject(AddItem(TObject(2))),TObject(1)] := TObject(6);
	end;
	EndUpdate();
end
1346
How can I specify the frame's color for all Task bars

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 128;
		Bars.Item['Task'].Def[EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(255);
	end;
	with Items do
	begin
		AddBar(AddItem('Task 1'),'Task','1/2/2001','1/5/2001','K1',Nil);
		AddBar(AddItem('Task 2'),'Task','1/2/2001','1/5/2001','K2',Nil);
		AddBar(AddItem('Task 3'),'Task','1/2/2001','1/5/2001','K3',Nil);
	end;
	EndUpdate();
end
1345
Is it possible to change the bar's frame color

with AxG2antt1 do
begin
	BeginUpdate();
	DefaultItemHeight := 25;
	Columns.Add('Task');
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 128;
		DrawGridLines := EXG2ANTTLib.GridLinesEnum.exHLines;
		NonworkingDays := 0;
		Bars.Item['Task'].Height := 15;
	end;
	with Items do
	begin
		h := AddItem('Default');
		AddBar(h,'Task','1/2/2001','1/5/2001','K1',Nil);
		h := AddItem('Red-Frame');
		AddBar(h,'Task','1/3/2001','1/6/2001','K1',Nil);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(255);
		h := AddItem('Green-ThickFrame');
		AddBar(h,'Task','1/4/2001','1/7/2001','K1',Nil);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarPattern] := TObject(4099);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(32768);
		h := AddItem('Red-ThickFrame/Shadow');
		AddBar(h,'Task','1/5/2001','1/8/2001','K1',Nil);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarPattern] := TObject(12291);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(255);
	end;
	EndUpdate();
end
1344
I need to customize the labels on the chart. Is it possible

with AxG2antt1 do
begin
	BeginUpdate();
	HeaderHeight := 32;
	with Chart do
	begin
		FirstVisibleDate := '7/1/2011';
		AdjustLevelsToBase := True;
		PaneWidth[False] := 0;
		LevelCount := 2;
		with Level[0] do
		begin
			Alignment := EXG2ANTTLib.AlignmentEnum.CenterAlignment;
			Label := '<b><%d%> - <%mmmm%> - <%yyyy%>';
			Unit := EXG2ANTTLib.UnitEnum.exDay;
		end;
		with Level[1] do
		begin
			Label := '<%h%>';
			Count := 8;
			Unit := EXG2ANTTLib.UnitEnum.exHour;
			FormatLabel := 'int(value) case ( 0 : ''Shift <b>1</b><br><font ;11>'' + yearday(dvalue) + ''</font>/365 '' ; 8 : ''Shift <b>2</b><br>'' + weekday(dva' + 
	'lue) + ''/20''; 16 : ''Shift <b>3</b><br>'' + (weekday(dvalue) case ( 0 : ''12/22''; 1 : ''12/23''; 2 : ''2/3''; 3 : ''12/13''; 4 : ''22/34'' ' + 
	'; 5 : ''102-<fgcolor=FF0000><b>31</b></bgcolor>''; 6 : ''1/1'' ) )  ) ';
		end;
		UnitWidth := 64;
		NonworkingDays := 0;
	end;
	EndUpdate();
end
1343
Is it possible to show a frame around the bar

with AxG2antt1 do
begin
	BeginUpdate();
	DefaultItemHeight := 25;
	with VisualAppearance do
	begin
		Add(1,'gBFLBCJwBAEHhEJAEGg4BOUMQAAYAQGKIYBkAKBQAGaAoDDYMgzQwAAxDELMEwsACEIrjKCVIgkHYJRjGEZxMAsEwjAoaQChEZRUhEMgxDDIIyAJIcaw0GSEZwgOQZBi' + 
	'OEYnDANkIYJDSIYHTZIUzTJAdGSVJKNKAoKCaEgORo5SpNUghBDYKQTJyeagkaaRVCWLplRCNIwWNJdVwjEaQaaiarKNqKNpSViAEqSdKEZRLOyRZyiKQMEreY4EUDQc' + 
	'xUPYMNYaAC6AAparpbwCFpSYpRND3TaEE4jSLKAA0HD6QqebIDDJaFq6PbVXSTOLPNhgPQcWxeVJBXjLExUALGSYLC6nKayHZcHACKK5VbVW6ZZDdNy/BLQeD4QANG4r' + 
	'iuNJriMV4dgWVgHh+ZpgCeEIQEQJIgGkMYdA6JwjC0VAAmaJgQgmPp4lCWgSCiaB+DKIYIjqQpllMf6JgYAoAmASAWAaAZggQDJ/gKYJIDYDoDmECBGAOBBhEgVgUgSY' + 
	'RoGYGYGCGKB2BCBwhmiBgLggIgoHoJIJGGKIeCiBYiiiLgXgCIpohoMIMGKGJODSCwghiZg6g6Y5InYPh/lAECAg');
		Add(2,'CP:1 2 2 -2 -2');
		Add(3,'CP:1 -5 -5 5 5');
		Add(4,'XP:Window 19 1');
		Add(5,'XP:TreeView 2 1');
	end;
	Columns.Add('Task');
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 128;
		DrawGridLines := EXG2ANTTLib.GridLinesEnum.exHLines;
	end;
	with Items do
	begin
		h := AddItem('Default');
		AddBar(h,'Task','1/2/2001','1/5/2001','K1',Nil);
		h := AddItem('Red-Frame');
		AddBar(h,'Task','1/3/2001','1/6/2001','K1',Nil);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(255);
		h := AddItem('Green-ThickFrame');
		AddBar(h,'Task','1/4/2001','1/7/2001','K1',Nil);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarPattern] := TObject(4099);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(32768);
		h := AddItem('Red-ThickFrame/Shadow');
		AddBar(h,'Task','1/4/2001','1/7/2001','K1',Nil);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarPattern] := TObject(12291);
		ItemBar[h,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(255);
		h := AddItem('EBN-Frame-Border');
		AddBar(h,'Task','1/5/2001','1/9/2001','K2',Nil);
		ItemBar[h,'K2',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(16777216);
		h := AddItem('EBN-Inside Frame');
		AddBar(h,'Task','1/9/2001','1/13/2001','K3',Nil);
		ItemBar[h,'K3',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(33554432);
		h := AddItem('EBN-Outside Frame');
		AddBar(h,'Task','1/15/2001','1/18/2001','K4',Nil);
		ItemBar[h,'K4',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(50331648);
		h := AddItem('EBN-XP Close Button');
		AddBar(h,'Task','1/15/2001','1/18/2001','K5',Nil);
		ItemBar[h,'K5',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(67108864);
		h := AddItem('EBN-XP TreeView Glyph');
		AddBar(h,'Task','1/15/2001','1/18/2001','K6',Nil);
		ItemBar[h,'K6',EXG2ANTTLib.ItemBarPropertyEnum.exBarFrameColor] := TObject(83886080);
	end;
	EndUpdate();
end
1342
Currently your control, provides customization up to Year,Month,Day,Hours,etc. I would like to add Shifts in a day. Shortly, I need to customize the chart's header. Is it possible

with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		FirstVisibleDate := '7/1/2011';
		AdjustLevelsToBase := True;
		PaneWidth[False] := 0;
		LevelCount := 2;
		with Level[0] do
		begin
			Alignment := EXG2ANTTLib.AlignmentEnum.CenterAlignment;
			Label := '<b><%d%> - <%mmmm%> - <%yyyy%>';
			Unit := EXG2ANTTLib.UnitEnum.exDay;
		end;
		with Level[1] do
		begin
			Label := '<%h%>';
			Count := 8;
			Unit := EXG2ANTTLib.UnitEnum.exHour;
			ReplaceLabel[0] := ' Shift 1';
			ReplaceLabel[8] := ' Shift 2';
			ReplaceLabel[16] := ' Shift 3';
		end;
		UnitWidth := 48;
		NonworkingDays := 0;
	end;
	EndUpdate();
end
1341
The exbartootip shows dates after you moved or resized the bar. My question is during the move or resizing of bar(you click on bar and drag it,during that time) , can we display the new dates simultaneously so we will know where we want to move or resize the bar to

with AxG2antt1 do
begin
	Columns.Add('Task');
	with Chart do
	begin
		PaneWidth[False] := 64;
		FirstVisibleDate := '1/1/2001';
		DrawDateTicker := True;
		DateTickerLabel := '<%mmm%> <%d%><br><b><%yyyy%>';
	end;
	with Items do
	begin
		h := AddItem('Tasks A');
		AddBar(h,'Task','1/2/2001','1/4/2001','K1',Nil);
		AddBar(h,'Task','1/5/2001','1/9/2001','K2',Nil);
		SelectableItem[AddItem(Nil)] := False;
		h := AddItem('Tasks B');
		AddBar(h,'Task','1/3/2001','1/5/2001','K1',Nil);
		AddBar(h,'Task','1/8/2001','1/11/2001','K2',Nil);
	end;
end
1340
Is it possible to assign a tooltip automatically to all bars, so it can display the start and end, without specifying the IexBarToolTip for each bar
with AxG2antt1 do
begin
	Columns.Add('Task');
	with Chart do
	begin
		PaneWidth[False] := 64;
		FirstVisibleDate := '1/1/2001';
		Bars.Item['Task'].Def[EXG2ANTTLib.ItemBarPropertyEnum.exBarToolTip] := '<b><%=%9 + ''/'' + %C0%></b><br><upline><dotline>Start: <%=%1%><br>End: <%=%2%><br>Duration: <%=(%2-%1)%><br>Working: <%=%258%>';
	end;
	with Items do
	begin
		h := AddItem('Tasks A');
		AddBar(h,'Task','1/2/2001','1/4/2001','K1',Nil);
		AddBar(h,'Task','1/5/2001','1/9/2001','K2',Nil);
		h := AddItem('Tasks B');
		AddBar(h,'Task','1/3/2001','1/5/2001','K1',Nil);
		AddBar(h,'Task','1/8/2001','1/11/2001','K2',Nil);
	end;
end
1339
How can I change the color, font, bold etc for the items/cells in the same column or for the entire column
with AxG2antt1 do
begin
	BeginUpdate();
	with ConditionalFormats.Add('1',Nil) do
	begin
		Bold := True;
		ForeColor := $ff;
		ApplyTo := EXG2ANTTLib.FormatApplyToEnum($1);
	end;
	Columns.Add('C1');
	with (Columns.Add('C2') as EXG2ANTTLib.Column) do
	begin
		HeaderBold := True;
		HTMLCaption := '<fgcolor=FF0000>C2';
	end;
	with Items do
	begin
		CellValue[TObject(AddItem(TObject(10))),TObject(1)] := TObject(11);
		CellValue[TObject(AddItem(TObject(12))),TObject(1)] := TObject(13);
	end;
	EndUpdate();
end
1338
How can I remove a date-time zone

// Click event - Occurs when the user presses and then releases the left mouse button over the tree control.
procedure TWinForm1.AxG2antt1_ClickEvent(sender: System.Object; e: System.EventArgs);
begin
	with AxG2antt1 do
	begin
		Chart.RemoveTimeZone('Z1');
	end
end;

with AxG2antt1 do
begin
	with Chart do
	begin
		PaneWidth[False] := 18;
		LevelCount := 2;
		FirstVisibleDate := '1/1/2010';
		MarkTimeZone('Z1','1/4/2010','1/8/2010',TObject(16744544),Nil);
	end;
end
1337
How can I filter the check-boxes (method 2)
with AxG2antt1 do
begin
	with (Columns.Add('Check') as EXG2ANTTLib.Column) do
	begin
		with Editor do
		begin
			EditType := EXG2ANTTLib.EditTypeEnum.CheckValueType;
			Option[EXG2ANTTLib.EditorOptionEnum.exCheckValue2] := TObject(1);
		end;
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		CustomFilter := 'checked||-1|||unchecked||0';
	end;
	with Items do
	begin
		AddItem(TObject(True));
		AddItem(TObject(True));
		AddItem(TObject(False));
		AddItem(TObject(True));
		AddItem(TObject(False));
		AddItem(TObject(True));
		AddItem(TObject(False));
	end;
end
1336
How can I filter the check-boxes (method 1)
with AxG2antt1 do
begin
	with (Columns.Add('Check') as EXG2ANTTLib.Column) do
	begin
		with Editor do
		begin
			EditType := EXG2ANTTLib.EditTypeEnum.CheckValueType;
			Option[EXG2ANTTLib.EditorOptionEnum.exCheckValue2] := TObject(1);
		end;
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		FilterType := EXG2ANTTLib.FilterTypeEnum.exCheck;
	end;
	with Items do
	begin
		AddItem(TObject(True));
		AddItem(TObject(True));
		AddItem(TObject(False));
		AddItem(TObject(True));
		AddItem(TObject(False));
		AddItem(TObject(True));
		AddItem(TObject(False));
	end;
end
1335
How can add a button to control

// ButtonClick event - Occurs when user clicks on the cell's button.
procedure TWinForm1.AxG2antt1_ButtonClick(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_ButtonClickEvent);
begin
	with AxG2antt1 do
	begin
		OutputDebugString( 'ButtonClick' );
		OutputDebugString( Items.CellCaption[TObject(e.item),TObject(e.colIndex)] );
		OutputDebugString( e.key );
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	DefaultItemHeight := 22;
	HeaderHeight := 22;
	Appearance := EXG2ANTTLib.AppearanceEnum.None2;
	DrawGridLines := EXG2ANTTLib.GridLinesEnum.exRowLines;
	ScrollBySingleLine := False;
	Images('gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTql' + 
	'Vq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0' + 
	'ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yN' + 
	'AOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=');
	set_HTMLPicture('pic1','c:\exontrol\images\auction.gif');
	Chart.PaneWidth[True] := 0;
	with Columns do
	begin
		with (Add('Type') as EXG2ANTTLib.Column) do
		begin
			Width := 48;
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueFormat] := TObject(1);
		end;
		with (Add('Appearance') as EXG2ANTTLib.Column) do
		begin
			Def[EXG2ANTTLib.DefColumnEnum.exCellValueFormat] := TObject(1);
			Alignment := EXG2ANTTLib.AlignmentEnum.CenterAlignment;
			HeaderAlignment := EXG2ANTTLib.AlignmentEnum.CenterAlignment;
		end;
	end;
	with Items do
	begin
		h := AddItem('Items.<b>CellHasButton</b> property');
		CellValue[TObject(h),TObject(1)] := 'Button <b>1</b>';
		CellHasButton[TObject(h),TObject(1)] := True;
		h := AddItem('Items.<b>CellButtonAutoWidth</b> property');
		CellValue[TObject(h),TObject(1)] := ' Button <b>2</b> ';
		CellHasButton[TObject(h),TObject(1)] := True;
		CellButtonAutoWidth[TObject(h),TObject(1)] := True;
		h := AddItem('Items.<b>CellHasButton</b> property');
		CellValue[TObject(h),TObject(1)] := ' <img>2</img>Button <b>3</b> ';
		CellHasButton[TObject(h),TObject(1)] := True;
		CellButtonAutoWidth[TObject(h),TObject(1)] := True;
		h := AddItem('Items.<b>CellHasButton</b> property');
		ItemHeight[h] := 32;
		CellValue[TObject(h),TObject(1)] := ' <img>2</img>Button <b>4</b> <img>pic1</img> ';
		CellHasButton[TObject(h),TObject(1)] := True;
		CellButtonAutoWidth[TObject(h),TObject(1)] := True;
		h := AddItem('Items.<b>CellHasButton</b> in splitted cells');
		CellValue[TObject(h),TObject(1)] := ' Button <b>5.1</b> ';
		CellHasButton[TObject(h),TObject(1)] := True;
		CellButtonAutoWidth[TObject(h),TObject(1)] := True;
		s := SplitCell[TObject(h),TObject(1)];
		CellValue[TObject(0),TObject(s)] := ' Button <b>5.2</b> ';
		CellHasButton[TObject(0),TObject(s)] := True;
		CellButtonAutoWidth[TObject(0),TObject(s)] := True;
		h := AddItem('Column.<b>Editor</b>, Items.<b>CellEditor</b>');
		CellValue[TObject(h),TObject(1)] := 'Visible when clicking the cell';
		with CellEditor[TObject(h),TObject(1)] do
		begin
			EditType := EXG2ANTTLib.EditTypeEnum.EditType;
			AddButton('B1',TObject(1),TObject(0),'This is a bit of text that''s shown when the cursor hovers the button B1',Nil,Nil);
			AddButton('B3',TObject(2),TObject(1),'This is a bit of text that''s shown when the cursor hovers the button B3',Nil,Nil);
			AddButton('B4',TObject(1),TObject(1),'This is a bit of text that''s shown when the cursor hovers the button B4',Nil,Nil);
			ButtonWidth := 24;
		end;
		h := AddItem('Column.<b>Editor</b>, Items.<b>CellEditor</b>');
		CellValue[TObject(h),TObject(1)] := TObject(3);
		with CellEditor[TObject(h),TObject(1)] do
		begin
			EditType := EXG2ANTTLib.EditTypeEnum.CheckListType;
			AddItem(1,'Flag 1',Nil);
			AddItem(2,'Flag 2',Nil);
			AddItem(4,'Flag 4',Nil);
			AddItem(8,'Flag 8',Nil);
			AddButton('C1',TObject(1),TObject(0),'This is a bit of text that''s shown when the cursor hovers the button C1',Nil,Nil);
			AddButton('C3',TObject(2),TObject(0),'This is a bit of text that''s shown when the cursor hovers the button C2',Nil,Nil);
			AddButton('C4',TObject(1),TObject(0),'This is a bit of text that''s shown when the cursor hovers the button C3',Nil,Nil);
			ButtonWidth := 24;
		end;
	end;
	EndUpdate();
end
1334
Is it posible to store additional values against each item, cell, bar, link, such as custom values such string / numbers etc
with AxG2antt1 do
begin
	with Chart do
	begin
		LevelCount := 2;
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 96;
	end;
	(Columns.Add('Column') as EXG2ANTTLib.Column).Data := 'Extra_Data_Column';
	with Items do
	begin
		h := AddItem('Item 1');
		ItemData[h] := 'Extra_Data_Item 1';
		CellData[TObject(h),TObject(0)] := 'Extra_Data_Item 1_Cell_0';
		AddBar(h,'Task','1/2/2001','1/4/2001','B1',Nil);
		ItemBar[h,'B1',EXG2ANTTLib.ItemBarPropertyEnum.exBarData] := 'Extra_B1_Data';
		h := AddItem('Item 2');
		ItemData[h] := 'Extra_Data_Item 2';
		AddBar(h,'Task','1/6/2001','1/10/2001','B2',Nil);
		ItemBar[h,'B2',EXG2ANTTLib.ItemBarPropertyEnum.exBarData] := 'Extra_B2_Data';
		AddLink('L1',FindItem['Item 1',TObject(0),Nil],'B1',FindItem['Item 2',TObject(0),Nil],'B2');
		Link['L1',EXG2ANTTLib.LinkPropertyEnum.exLinkUserData] := 'Extra_Link_Data';
	end;
end
1333
How do I set the parent item to show the total number of days for its children and also the minimum and maximum dates for its children

with AxG2antt1 do
begin
	BeginUpdate();
	MarkSearchColumn := False;
	Indent := 11;
	HasLines := EXG2ANTTLib.HierarchyLineEnum.exSolidLine;
	Items.AllowCellValueToItemBar := True;
	with Columns do
	begin
		Add('Tasks');
		(Add('Start') as EXG2ANTTLib.Column).Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(1);
		(Add('End') as EXG2ANTTLib.Column).Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(2);
		(Add('Duration') as EXG2ANTTLib.Column).Def[EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty] := TObject(513);
	end;
	with Chart do
	begin
		ShowNonworkingDates := False;
		FirstVisibleDate := '9/20/2006';
		AllowLinkBars := False;
		AllowCreateBar := EXG2ANTTLib.CreateBarEnum.exNoCreateBar;
		LevelCount := 2;
		PaneWidth[False] := 220;
	end;
	with Items do
	begin
		h := AddItem('Project');
		AddBar(h,'Summary','9/21/2006','10/3/2006',Nil,Nil);
		h1 := InsertItem(h,Nil,'Task 1');
		AddBar(h1,'Task','9/21/2006','9/24/2006',Nil,Nil);
		h2 := InsertItem(h,Nil,'Task 2');
		AddBar(h2,'Task','9/24/2006','9/28/2006',Nil,Nil);
		h3 := InsertItem(h,Nil,'Task 3');
		AddBar(h3,'Task','9/28/2006','10/3/2006',Nil,Nil);
		DefineSummaryBars(h,'',h1,'');
		DefineSummaryBars(h,'',h2,'');
		DefineSummaryBars(h,'',h3,'');
		ExpandItem[h] := True;
		ItemBold[h] := True;
	end;
	EndUpdate();
end
1332
Is it possible to specify the distance between 2 bars to be at least 2 working days

// BarResizing event - Occurs when a bar is moving or resizing.
procedure TWinForm1.AxG2antt1_BarResizing(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_BarResizingEvent);
begin
	with AxG2antt1 do
	begin
		Items.SchedulePDM(e.item,TObject(e.key));
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	DefaultItemHeight := 24;
	AntiAliasing := True;
	Columns.Add('Task');
	with Chart do
	begin
		LevelCount := 2;
		with Bars.Add('Task:Split') do
		begin
			Shortcut := 'Task';
			Color := $0;
			Height := 17;
			Pattern := EXG2ANTTLib.PatternEnum.exPatternFrameShadow;
		end;
		FirstVisibleDate := '1/3/2001';
		PaneWidth[False] := 48;
		LinksWidth := 2;
		AllowCreateBar := EXG2ANTTLib.CreateBarEnum.exNoCreateBar;
		AllowLinkBars := False;
		FirstWeekDay := EXG2ANTTLib.WeekDayEnum.exMonday;
		NonworkingDaysPattern := EXG2ANTTLib.PatternEnum.exPatternBDiagonal;
	end;
	with Items do
	begin
		h1 := AddItem('Task 1');
		AddBar(h1,'Task','1/4/2001','1/6/2001','K1',Nil);
		ItemBar[h1,'K1',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
		h2 := AddItem('Task 2');
		AddBar(h2,'Task','1/2/2001','1/5/2001','K2',Nil);
		ItemBar[h2,'K2',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
		AddLink('L1',h1,'K1',h2,'K2');
		Link['L1',EXG2ANTTLib.LinkPropertyEnum.exLinkShowRound] := TObject(-1);
		Link['L1',EXG2ANTTLib.LinkPropertyEnum.exLinkColor] := TObject(8421504);
		h3 := AddItem('Task 3');
		AddBar(h3,'Task','1/2/2001','1/6/2001','K3',Nil);
		ItemBar[h3,'K3',EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount] := TObject(True);
		AddLink('L2',h2,'K2',h3,'K3');
		Link['L2',EXG2ANTTLib.LinkPropertyEnum.exLinkText] := '<br><br><br><br>This link <u>delays</u> the bars<br>with <b>2</b> working days';
		Link['L2',EXG2ANTTLib.LinkPropertyEnum.exLinkPDMWorkingDelay] := TObject(2);
		Link['L2',EXG2ANTTLib.LinkPropertyEnum.exLinkShowRound] := TObject(-1);
		SchedulePDM(0,'K1');
	end;
	EndUpdate();
end
1331
The item is not getting selected when clicking the cell's checkbox. What should I do
// CellStateChanged event - Fired after cell's state has been changed.
procedure TWinForm1.AxG2antt1_CellStateChanged(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_CellStateChangedEvent);
begin
	with AxG2antt1 do
	begin
		Items.SelectItem[e.item] := True;
	end
end;

with AxG2antt1 do
begin
	(Columns.Add('Check') as EXG2ANTTLib.Column).Def[EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox] := TObject(True);
	with Items do
	begin
		AddItem(TObject(0));
		AddItem(TObject(1));
		AddItem(TObject(2));
		AddItem(TObject(3));
	end;
end
1330
How can I add a summary item as a child or subitem of another one

with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		PaneWidth[False] := 96;
		FirstVisibleDate := '1/1/2011';
		LevelCount := 2;
	end;
	Columns.Add('Default');
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with Items do
	begin
		hSummary := AddItem('Project');
		AddBar(hSummary,'Summary','1/1/2011','1/1/2011','Sum',Nil);
		hChild := InsertItem(hSummary,TObject(0),'Task 1');
		AddBar(hChild,'Task','1/2/2011','1/4/2011','Task1',Nil);
		DefineSummaryBars(hSummary,'Sum',hChild,'Task1');
		hChild := InsertItem(hSummary,TObject(0),'Task 2');
		AddBar(hChild,'Task','1/4/2011','1/6/2011','Task2',Nil);
		DefineSummaryBars(hSummary,'Sum',hChild,'Task2');
		hChild := InsertItem(hSummary,TObject(0),'Task 3');
		AddBar(hChild,'Task','1/6/2011','1/8/2011','Task3',Nil);
		DefineSummaryBars(hSummary,'Sum',hChild,'Task3');
		ExpandItem[hSummary] := True;
	end;
	EndUpdate();
end
1329
How can I make an item a subitem of another one
with AxG2antt1 do
begin
	BeginUpdate();
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	Chart.PaneWidth[True] := 0;
	Columns.Add('Default');
	with Items do
	begin
		hSummary := AddItem('Project');
		hChild := InsertItem(hSummary,TObject(0),'Task 1');
		hChild := InsertItem(hSummary,TObject(0),'Task 2');
		hChild := InsertItem(hSummary,TObject(0),'Task 3');
		ExpandItem[hSummary] := True;
	end;
	EndUpdate();
end
1328
Is it possible to move a bar per drag and drop to another owner/item
with AxG2antt1 do
begin
	BeginUpdate();
	(Columns.Add('Members') as EXG2ANTTLib.Column).Def[EXG2ANTTLib.DefColumnEnum.exCellValueFormat] := TObject(1);
	with Chart do
	begin
		FirstVisibleDate := '9/20/2006';
		AllowLinkBars := False;
		AllowCreateBar := EXG2ANTTLib.CreateBarEnum.exNoCreateBar;
		AllowSelectObjects := EXG2ANTTLib.SelectObjectsEnum.exNoSelectObjects;
		LevelCount := 2;
		PaneWidth[False] := 96;
		Bars.Item['Task'].OverlaidType := Integer(EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsIncludeCaption) Or Integer(EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStackAutoArrange) Or Integer(EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStack);
	end;
	with Items do
	begin
		h := AddItem('Member <b>1</b>');
		AddBar(h,'Task','9/21/2006','9/23/2006','T102','Task <b>102</b>');
		ItemBar[h,'T102',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'T102',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanMoveToAnother] := TObject(True);
		h := AddItem('Member <b>2</b>');
		h := AddItem('Member <b>3</b>');
		h := AddItem('Member <b>4</b>');
		AddBar(h,'Task','9/21/2006','9/23/2006','T103','Task <b>103</b>');
		ItemBar[h,'T103',EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption] := TObject(18);
		ItemBar[h,'T103',EXG2ANTTLib.ItemBarPropertyEnum.exBarCanMoveToAnother] := TObject(True);
	end;
	EndUpdate();
end
1327
I have the chart displaying days, is it possible to display bars/tasks up to hours so inside days somehow
with AxG2antt1 do
begin
	BeginUpdate();
	with Chart do
	begin
		LevelCount := 2;
		UnitWidth := 38;
		PaneWidth[False] := 28;
		FirstVisibleDate := '3/4/2011';
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		ResizeUnitScale := EXG2ANTTLib.UnitEnum.exHour;
	end;
	Columns.Add('Default');
	with Items do
	begin
		AddBar(AddItem('ASS'),'Task','3/7/2011','3/7/2011 3:30:00 AM',Nil,Nil);
		AddBar(AddItem('EMB'),'Task','3/7/2011 3:30:00 AM','3/8/2011 9:15:00 AM',Nil,Nil);
		AddBar(AddItem('TES'),'Task','3/8/2011 9:15:00 AM','3/8/2011 1:45:00 PM',Nil,Nil);
	end;
	EndUpdate();
end
1326
Is it possible to limit the height of the item while resizing
// AddItem event - Occurs after a new Item has been inserted to Items collection.
procedure TWinForm1.AxG2antt1_AddItem(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_AddItemEvent);
begin
	with AxG2antt1 do
	begin
		Items.ItemMinHeight[e.item] := 18;
		Items.ItemMaxHeight[e.item] := 72;
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	ItemsAllowSizing := EXG2ANTTLib.ItemsAllowSizingEnum.exResizeItem;
	ScrollBySingleLine := False;
	BackColorAlternate := Color.FromArgb(240,240,240);
	Columns.Add('Names');
	with Items do
	begin
		AddItem('Mantel');
		AddItem('Mechanik');
		AddItem('Motor');
		AddItem('Murks');
		AddItem('Märchen');
		AddItem('Möhren');
		AddItem('Mühle');
	end;
	Columns.Item[TObject(0)].SortOrder := EXG2ANTTLib.SortOrderEnum.SortAscending;
	EndUpdate();
end
1325
Is it possible to copy the hierarchy of the control using the GetItems method
with AxG2antt1 do
begin
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	Columns.Add('Def');
	with Items do
	begin
		h := AddItem('Root');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
	end;
	PutItems(GetItems(TObject(-1)),Nil);
end
1324
I have found a property ReadOnly but this doesn't work correctly. I need the chart part of the control to be readonly too. Is it possible
with AxG2antt1 do
begin
	ReadOnly := EXG2ANTTLib.ReadOnlyEnum.exReadOnly;
	with Chart do
	begin
		AllowCreateBar := EXG2ANTTLib.CreateBarEnum.exNoCreateBar;
		BarsAllowSizing := False;
		AllowLinkBars := False;
	end;
end
1323
How can I select a column
// MouseDown event - Occurs when the user presses a mouse button.
procedure TWinForm1.AxG2antt1_MouseDownEvent(sender: System.Object; e: AxEXG2ANTTLib._IG2anttEvents_MouseDownEvent);
begin
	with AxG2antt1 do
	begin
		BeginUpdate();
		Columns.Item[TObject(AxG2antt1.ColumnFromPoint[e.x,e.y])].Selected := True;
		Items.SelectAll();
		EndUpdate();
	end
end;

with AxG2antt1 do
begin
	BeginUpdate();
	MarkSearchColumn := False;
	SingleSel := False;
	FullRowSelect := EXG2ANTTLib.CellSelectEnum.exRectSel;
	SortOnClick := EXG2ANTTLib.SortOnClickEnum.exNoSort;
	with Columns do
	begin
		Add('Column1');
		Add('Column2');
	end;
	with Items do
	begin
		CellValue[TObject(AddItem('One')),TObject(1)] := 'One';
		CellValue[TObject(AddItem('Two')),TObject(1)] := 'Two';
	end;
	EndUpdate();
end
1322
I have several columns, but noticed that the filter is using AND between columns, but I need OR clause for filtering. Is it possible
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with (Columns.Add('Item') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		Filter := 'Child 1';
		FilterType := EXG2ANTTLib.FilterTypeEnum.exFilter;
	end;
	with (Columns.Add('Date') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		DisplayFilterDate := True;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowExclude) Or Integer(EXG2ANTTLib.FilterListEnum.exShowFocusItem) Or Integer(EXG2ANTTLib.FilterListEnum.exShowCheckBox) Or Integer(EXG2ANTTLib.FilterListEnum.exNoItems);
		Filter := '12/28/2010';
		FilterType := EXG2ANTTLib.FilterTypeEnum.exDate;
	end;
	FilterCriteria := '%0 or %1';
	set_Description(EXG2ANTTLib.DescriptionTypeEnum.exFilterBarOr,'<font ;18><fgcolor=FF0000>or</fgcolor></font>');
	set_Description(EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,'<font ;18><fgcolor=FF0000>and</fgcolor></font>');
	with Items do
	begin
		h := AddItem('Root 1');
		CellValue[TObject(InsertItem(h,Nil,'Child 1')),TObject(1)] := '12/27/2010';
		CellValue[TObject(InsertItem(h,Nil,'Child 2')),TObject(1)] := '12/28/2010';
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		CellValue[TObject(InsertItem(h,Nil,'Child 1')),TObject(1)] := '12/29/2010';
		CellValue[TObject(InsertItem(h,Nil,'Child 2')),TObject(1)] := '12/30/2010';
	end;
	ApplyFilter();
	EndUpdate();
end
1321
Is it possible exclude the dates being selected in the drop down filter window
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	with (Columns.Add('Date') as EXG2ANTTLib.Column) do
	begin
		SortType := EXG2ANTTLib.SortTypeEnum.SortDate;
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		DisplayFilterDate := True;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowExclude) Or Integer(EXG2ANTTLib.FilterListEnum.exShowFocusItem) Or Integer(EXG2ANTTLib.FilterListEnum.exShowCheckBox) Or Integer(EXG2ANTTLib.FilterListEnum.exNoItems);
	end;
	with Items do
	begin
		AddItem('12/27/2010');
		AddItem('12/28/2010');
		AddItem('12/29/2010');
		AddItem('12/30/2010');
		AddItem('12/31/2010');
	end;
	EndUpdate();
end
1320
How can I display a calendar control inside the drop down filter window
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	with (Columns.Add('Date') as EXG2ANTTLib.Column) do
	begin
		SortType := EXG2ANTTLib.SortTypeEnum.SortDate;
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		DisplayFilterDate := True;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowFocusItem) Or Integer(EXG2ANTTLib.FilterListEnum.exShowCheckBox) Or Integer(EXG2ANTTLib.FilterListEnum.exNoItems);
	end;
	with Items do
	begin
		AddItem('12/27/2010');
		AddItem('12/28/2010');
		AddItem('12/29/2010');
		AddItem('12/30/2010');
		AddItem('12/31/2010');
	end;
	EndUpdate();
end
1319
Is it possible to include the dates as checkb-boxes in the drop down filter window
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	with (Columns.Add('Dates') as EXG2ANTTLib.Column) do
	begin
		SortType := EXG2ANTTLib.SortTypeEnum.SortDate;
		DisplayFilterButton := True;
		DisplayFilterPattern := True;
		DisplayFilterDate := True;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowFocusItem) Or Integer(EXG2ANTTLib.FilterListEnum.exShowCheckBox);
		Filter := 'to 12/27/2010';
		FilterType := EXG2ANTTLib.FilterTypeEnum.exDate;
	end;
	with Items do
	begin
		AddItem('12/27/2010');
		AddItem('12/28/2010');
		AddItem('12/29/2010');
		AddItem('12/30/2010');
		AddItem('12/31/2010');
	end;
	ApplyFilter();
	EndUpdate();
end
1318
How can I filter items for dates before a specified date
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	with (Columns.Add('Dates') as EXG2ANTTLib.Column) do
	begin
		SortType := EXG2ANTTLib.SortTypeEnum.SortDate;
		DisplayFilterButton := True;
		DisplayFilterPattern := True;
		DisplayFilterDate := True;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowFocusItem) Or Integer(EXG2ANTTLib.FilterListEnum.exNoItems);
		Filter := 'to 12/27/2010';
		FilterType := EXG2ANTTLib.FilterTypeEnum.exDate;
	end;
	with Items do
	begin
		AddItem('12/27/2010');
		AddItem('12/28/2010');
		AddItem('12/29/2010');
		AddItem('12/30/2010');
		AddItem('12/31/2010');
	end;
	ApplyFilter();
	EndUpdate();
end
1317
Is it possible to filter dates
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	with (Columns.Add('Dates') as EXG2ANTTLib.Column) do
	begin
		SortType := EXG2ANTTLib.SortTypeEnum.SortDate;
		DisplayFilterButton := True;
		DisplayFilterPattern := True;
		DisplayFilterDate := True;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowFocusItem) Or Integer(EXG2ANTTLib.FilterListEnum.exNoItems);
	end;
	with Items do
	begin
		AddItem('12/27/2010');
		AddItem('12/28/2010');
		AddItem('12/29/2010');
		AddItem('12/30/2010');
		AddItem('12/31/2010');
	end;
	EndUpdate();
end
1316
Is it possible to change the Exclude field name to something different, in the drop down filter window
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	set_Description(EXG2ANTTLib.DescriptionTypeEnum.exFilterBarExclude,'Leaving out');
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowExclude) Or Integer(EXG2ANTTLib.FilterListEnum.exShowFocusItem) Or Integer(EXG2ANTTLib.FilterListEnum.exShowCheckBox);
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
	end;
	EndUpdate();
end
1315
How can I display the Exclude field in the drop down filter window
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowExclude) Or Integer(EXG2ANTTLib.FilterListEnum.exShowFocusItem) Or Integer(EXG2ANTTLib.FilterListEnum.exShowCheckBox);
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
	end;
	EndUpdate();
end
1314
Is it possible to show and ensure the focused item from the control, in the drop down filter window
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowFocusItem) Or Integer(EXG2ANTTLib.FilterListEnum.exShowCheckBox);
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		SelectItem[InsertItem(h,Nil,'Child 2')] := True;
		ExpandItem[h] := True;
	end;
	EndUpdate();
end
1313
Is it possible to show only blanks items with no listed items from the control
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowBlanks) Or Integer(EXG2ANTTLib.FilterListEnum.exNoItems);
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
	end;
	EndUpdate();
end
1312
How can I include the blanks items in the drop down filter window
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		FilterList := Integer(EXG2ANTTLib.FilterListEnum.exShowBlanks) Or Integer(EXG2ANTTLib.FilterListEnum.exShowCheckBox);
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
	end;
	EndUpdate();
end
1311
How can I select multiple items in the drop down filter window, using check-boxes
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		FilterList := EXG2ANTTLib.FilterListEnum.exShowCheckBox;
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
	end;
	EndUpdate();
end
1310
Is it possible to allow a single item being selected in the drop down filter window
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := False;
		FilterList := EXG2ANTTLib.FilterListEnum.exSingleSel;
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
	end;
	EndUpdate();
end
1309
How can I display no (All) item in the drop down filter window
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	set_Description(EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAll,'');
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := True;
		FilterList := EXG2ANTTLib.FilterListEnum.exNoItems;
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
	end;
	EndUpdate();
end
1308
Is it possible to display no items in the drop down filter window, so only the pattern is visible
with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		DisplayFilterPattern := True;
		FilterList := EXG2ANTTLib.FilterListEnum.exNoItems;
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
	end;
	EndUpdate();
end
1307
How can I specify the time-scale available when zoom-in/zoom-out or enlarging the chart
with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 48;
		ShowNonworkingDates := False;
		LevelCount := 3;
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		AllowResizeChart := Integer(EXG2ANTTLib.ResizeChartEnum.exAllowChangeUnitScale) Or Integer(EXG2ANTTLib.ResizeChartEnum.exAllowResizeChartMiddle) Or Integer(EXG2ANTTLib.ResizeChartEnum.exAllowResizeChartHeader);
		Label[EXG2ANTTLib.UnitEnum.exHour] := '';
		Label[EXG2ANTTLib.UnitEnum.exMinute] := '';
		Label[EXG2ANTTLib.UnitEnum.exSecond] := '';
	end;
	with Items do
	begin
		AddBar(AddItem('Task A'),'Task','1/2/2001','1/6/2001','K1',Nil);
		AddBar(AddItem('Task B'),'Task','1/6/2001','1/10/2001','K1',Nil);
		AddBar(AddItem('Task C'),'Task','1/10/2001','1/14/2001','K1',Nil);
		AddBar(AddItem(''),'','1/8/2001','1/8/2001','Info','Click the <b>middle</b> mouse button and start dragging');
	end;
	EndUpdate();
end
1306
How can I enable zoom-in/zoom-out or enlarging the chart, using the mouse middle button
with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 48;
		ShowNonworkingDates := False;
		LevelCount := 3;
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		AllowResizeChart := Integer(EXG2ANTTLib.ResizeChartEnum.exAllowChangeUnitScale) Or Integer(EXG2ANTTLib.ResizeChartEnum.exAllowResizeChartMiddle) Or Integer(EXG2ANTTLib.ResizeChartEnum.exAllowResizeChartHeader);
	end;
	with Items do
	begin
		AddBar(AddItem('Task A'),'Task','1/2/2001','1/6/2001','K1',Nil);
		AddBar(AddItem('Task B'),'Task','1/6/2001','1/10/2001','K1',Nil);
		AddBar(AddItem('Task C'),'Task','1/10/2001','1/14/2001','K1',Nil);
		AddBar(AddItem(''),'','1/8/2001','1/8/2001','Info','Click the <b>middle</b> mouse button and start dragging');
	end;
	EndUpdate();
end
1305
How can I enable zoom-in/zoom-out or enlarging, using the chart's header

with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 48;
		ShowNonworkingDates := False;
		LevelCount := 3;
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		AllowResizeChart := Integer(EXG2ANTTLib.ResizeChartEnum.exAllowChangeUnitScale) Or Integer(EXG2ANTTLib.ResizeChartEnum.exAllowResizeChartHeader);
	end;
	with Items do
	begin
		AddBar(AddItem('Task A'),'Task','1/2/2001','1/6/2001','K1',Nil);
		AddBar(AddItem('Task B'),'Task','1/6/2001','1/10/2001','K1',Nil);
		AddBar(AddItem('Task C'),'Task','1/10/2001','1/14/2001','K1',Nil);
	end;
	EndUpdate();
end
1304
How can I enable resizing the chart, using the mouse middle button
with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 48;
		ShowNonworkingDates := False;
		LevelCount := 3;
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		AllowResizeChart := Integer(EXG2ANTTLib.ResizeChartEnum.exAllowResizeChartMiddle) Or Integer(EXG2ANTTLib.ResizeChartEnum.exAllowResizeChartHeader);
		MaxUnitWidth := 128;
		MinUnitWidth := 8;
	end;
	with Items do
	begin
		AddBar(AddItem('Task A'),'Task','1/2/2001','1/6/2001','K1',Nil);
		AddBar(AddItem('Task B'),'Task','1/6/2001','1/10/2001','K1',Nil);
		AddBar(AddItem('Task C'),'Task','1/10/2001','1/14/2001','K1',Nil);
		AddBar(AddItem(''),'','1/8/2001','1/8/2001','Info','Click the <b>middle</b> mouse button and start dragging');
	end;
	EndUpdate();
end
1303
How can I enable resizing the chart, using the chart's header
with AxG2antt1 do
begin
	BeginUpdate();
	Columns.Add('Task');
	with Chart do
	begin
		FirstVisibleDate := '1/1/2001';
		PaneWidth[False] := 48;
		ShowNonworkingDates := False;
		LevelCount := 3;
		UnitScale := EXG2ANTTLib.UnitEnum.exDay;
		AllowResizeChart := EXG2ANTTLib.ResizeChartEnum.exAllowResizeChartHeader;
		MaxUnitWidth := 128;
		MinUnitWidth := 8;
	end;
	with Items do
	begin
		AddBar(AddItem('Task A'),'Task','1/2/2001','1/6/2001','K1',Nil);
		AddBar(AddItem('Task B'),'Task','1/6/2001','1/10/2001','K1',Nil);
		AddBar(AddItem('Task C'),'Task','1/10/2001','1/14/2001','K1',Nil);
	end;
	EndUpdate();
end
1302
Is it possible to auto-numbering the children items but still keeps the position after filtering

with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	with (Columns.Add('Items') as EXG2ANTTLib.Column) do
	begin
		DisplayFilterButton := True;
		FilterType := EXG2ANTTLib.FilterTypeEnum.exFilter;
		Filter := 'Child 2';
	end;
	with (Columns.Add('Pos.1') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '1 ropos ''''';
		Position := 0;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.2') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '1 ropos '':''';
		Position := 1;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.3') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '1 ropos '':|A-Z''';
		Position := 2;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.4') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '1 ropos ''|A-Z|''';
		Position := 3;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.5') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '''<font Tahoma;7>'' + 1 ropos ''-<b>||A-Z''';
		Def[EXG2ANTTLib.DefColumnEnum.exCellValueFormat] := TObject(1);
		Position := 4;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.6') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '''<b>''+ 1 ropos ''</b>:<fgcolor=FF0000>|A-Z|''';
		Def[EXG2ANTTLib.DefColumnEnum.exCellValueFormat] := TObject(1);
		Position := 5;
		Width := 48;
		AllowSizing := False;
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
	end;
	ApplyFilter();
	EndUpdate();
end
1301
Is it possible to auto-numbering the children items too

with AxG2antt1 do
begin
	BeginUpdate();
	Chart.PaneWidth[True] := 0;
	LinesAtRoot := EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot;
	Columns.Add('Items');
	with (Columns.Add('Pos.1') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '1 rpos ''''';
		Position := 0;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.2') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '1 rpos '':''';
		Position := 1;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.3') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '1 rpos '':|A-Z''';
		Position := 2;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.4') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '1 rpos ''|A-Z|''';
		Position := 3;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.5') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '''<font Tahoma;7>'' + 1 rpos ''-<b>||A-Z''';
		Def[EXG2ANTTLib.DefColumnEnum.exCellValueFormat] := TObject(1);
		Position := 4;
		Width := 32;
		AllowSizing := False;
	end;
	with (Columns.Add('Pos.6') as EXG2ANTTLib.Column) do
	begin
		FormatColumn := '''<b>''+ 1 rpos ''</b>:<fgcolor=FF0000>|A-Z|''';
		Def[EXG2ANTTLib.DefColumnEnum.exCellValueFormat] := TObject(1);
		Position := 5;
		Width := 48;
		AllowSizing := False;
	end;
	with Items do
	begin
		h := AddItem('Root 1');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
		ExpandItem[h] := True;
		h := AddItem('Root 2');
		InsertItem(h,Nil,'Child 1');
		InsertItem(h,Nil,'Child 2');
	end;
	EndUpdate();
end